I'm using the indicator Swing(5).SwingHigh[1] in my strategy. Here is the code that I'm using to output the indicator:
Print("Current Swing High(5) is " + Swing(5).SwingHigh[1].ToString() + " at " + Time[0].ToString());
I'm running this indicator under this routine:
if (FirstTickOfBar)
However, as soon as the Swing High is breached, I'm getting a bad value. See attached. How is this indicator supposed to be calculated in this instance. I would have thought it would return null.
Thanks,
Rich
Comment