R2 = Pivots(PivotRange.Daily, HLCCalculationMode.CalcFromIntradayData, 0, 0, 0, 20).R2[0];
but something is odd...
It doesn't always match the Pivots Indicator placed on a Chart that also calculates from Intraday data ... right now I'm testing on forex, I haven't tried it on futures yet.
It seems to me that the pivot indicator in the code above is starting the day at a different time zone than the Pivot Indicator placed on a chart.
Can someone explain how to get the Pivots indicator in code to be the same as the one on the chart... I assume the one on the chart is using the forex session template.
The reason I suspect a time zone mismatch is because they agree on the levels during the trading day, but I noticed the mismatch at midnight local time (I think). I went to bed though so I'm not sure how long it lasted for.
Comment