It seems you are using the current RSI value in your checks, something that can cause false signals since the value can change by the time the candle is finalized. Try this instead
bool closeLoss = rsi.Result.Last(1)< RsiCloseLoss && rsi.Result.Last(2) < RsiCloseLoss; bool closeProfit = rsi.Result.Last(1) > RsiCloseProfit && rsi.Result.Last(2) > RsiCloseProfit;if (closeLoss || closeProfit){ CloseAllPositions(); //Just normal Close all positions}
dkt0591
12 Nov 2024, 09:02 ( Updated at: 12 Nov 2024, 11:13 )
RE: Ctrader Algo sometimes missed signal!
PanagiotisCharalampous said:
Thank you
@dkt0591