Implement Position Protector ...

need to test BE Hedge ...
This commit is contained in:
2024-09-18 21:13:23 +03:30
parent dbdbb3a276
commit 9393c9ecfe
7 changed files with 623 additions and 119 deletions
+5 -2
View File
@@ -579,10 +579,13 @@ struct XPosition
}
//
double point = GetPoints(symbol);
double tickSize = SymbolInfoDouble(symbol, SYMBOL_TRADE_TICK_SIZE); // Tick size
double tickValue = SymbolInfoDouble(symbol, SYMBOL_TRADE_TICK_VALUE); // Tick value
double pointSize = SymbolInfoDouble(symbol, SYMBOL_POINT); // Point size
double pointValue = tickValue * pointSize / tickSize; // Point value
//
result = profit * point;
result = profit / (volume * tickValue);
//
return result;