how can I tell Ninjatrader ( in indicator mode) to tell me what was the Max amount of bars back when the close was higher than the 10 EMA line starting from today going backwards.
I found this formula online but it not exactly correct.
int NumBullishCandle = CountIf(delegate {return Close[0] > EMA(10)[0];}, 20); Plot0.Set(NumBullishCandle);
Also its going to be important to have it in Plot mode. Not print.
Thank you
Comment