Hi all,
I would like to screen for stocks which recently had a turnaround in the MACD signal (see arrow in attachment).
To do this I need to create a formula which gives me the day (bars ago) in last 15 trading days with the lowest MACDD signal value, but not the value itself.
To get the lowest value itself I would simply use LoopMin
LoopMin("MACDD(12,26,1,CTR)",15)
But what I am after is the CTR when this lowest value occurs, which fulfills the following condition:
MACDD(12,26,1,CTR)<MACDD(12,26,1,CTR+1) AND MACDD(12,26,1,CTR)<MACDD(12,26,1,CTR-1)
Does anybody know how I can implement this in a loop and get the CTR as answer, like
Eval(condition with loop, CTR,0)
Best regards,
Florian