обновление стопов
test / deploy_trader_prod (push) Successful in 1m33s Details

dev
vlad zverzhkhovskiy 2025-09-23 16:08:11 +03:00
parent 4dc37f4bbc
commit 30552816f6
1 changed files with 9 additions and 9 deletions

View File

@ -706,46 +706,46 @@ INewPrice message, int windowMaxSize, decimal uptrendStartingDetectionMeanfullSt
private (decimal stopLoss, decimal takeProfit) GetStops(INewPrice message, PositionType type)
{
var mode = TradingModes[message.Figi];
decimal stopLossShift = 10;
decimal stopLossShift = 3;
decimal takeProfitShift = 5;
if (mode == TradingMode.Growing && type == PositionType.Long)
{
stopLossShift = 10;
stopLossShift = 8;
takeProfitShift = 15;
}
if (mode == TradingMode.Growing && type == PositionType.Short)
{
stopLossShift = 10;
stopLossShift = 4;
takeProfitShift = 2;
}
if (mode == TradingMode.Stable && type == PositionType.Long)
{
stopLossShift = 10;
stopLossShift = 4;
takeProfitShift = 2.5m;
}
if (mode == TradingMode.Stable && type == PositionType.Short)
{
stopLossShift = 10;
stopLossShift = 4;
takeProfitShift = 2.5m;
}
if (mode == TradingMode.SlowDropping && type == PositionType.Short)
{
stopLossShift = 10;
stopLossShift = 6;
takeProfitShift = 2.5m;
}
if (mode == TradingMode.SlowDropping && type == PositionType.Long)
{
stopLossShift = 10;
stopLossShift = 4;
takeProfitShift = 1.5m;
}
if (mode == TradingMode.Dropping && type == PositionType.Short)
{
stopLossShift = 10;
stopLossShift = 4;
takeProfitShift = 13;
}
if (mode == TradingMode.Dropping && type == PositionType.Long)
{
stopLossShift = 10;
stopLossShift = 4;
takeProfitShift = 1.5m;
}
return (stopLossShift, takeProfitShift);