class IndicatorAbc
Initialize()
{
CalculateOnBarClose = false;
...
if (BarsPeriod.Id == PeriodType.Minute)
Add(PeriodType.Day, 1);
}
OnBarUpdate()
{
if (BarsInProgress == 0 && CurrentBars[0] >= 2) // if working on intraday, add daily info
{
double todaysSignalSoFar = IndicatorAbc(BarsArray[1]).SomeSignal[0]; // daily signal (so far)
double previousLow = Low[1][1]; // previous daily low
}
}
However todaysSignalSoFar is showing yesterday's EOD signal.
And previousLow is actually showing the low from 2 days ago.
Something odd also happens if I access Low[1][0] as it also shows the previous day's low rather than the current low. CalculateOnBarClose = false for both.
Currently this to chart historical but was planning to use within a strategy and for live charting. I suspect the index values will change with the switch to live charting but I wish the live vs historical to behave consistently for index[0].
Is there a way to to make BarsArray[1][0] contain the current day's value recalculated at the current intraday point?
Thanks,
Chris
Comment