Range of bars for a condition to be met
-
Hello. I want to make that, after a condition has been met, the next condition must be met in the next 5 bars.
For example: if EMA 20 cross over EMA 10 and MACD´s value is up to 0 in the same bar, in the next 5 bars MACD´s value will be must cross down 0.
Someone knows how can I do it? I have tried with a minute timer, but does not seem to work as I want.
-
try to look through my replies and find example about "flags" or "counters, candle counter, etc" ... I am not sure where I was replied about it but it was more times about the same question
