protected override void OnDataPoint(Bars bars, double open, [B]double high, double low, double close[/B], DateTime time, long volume, bool isBar, double bid, double ask)
{
if (SessionIterator == null)
SessionIterator = new SessionIterator(bars);
bool isNewSession = SessionIterator.IsNewSession(time, isBar);
if (isNewSession)
SessionIterator.GetNextSession(time, isBar);
if (bars.Count == 0 || bars.IsResetOnNewTradingDay && isNewSession)
AddBar(bars, open, high, low, close, time, volume);
else
{
[B] double barClose = bars.GetClose(bars.Count - 1);
double barHigh = bars.GetHigh(bars.Count - 1);
double barLow = bars.GetLow(bars.Count - 1); [/B]
double tickSize = bars.Instrument.MasterInstrument.TickSize;
double rangeValue = Math.Floor(10000000.0 * bars.BarsPeriod.Value * tickSize) / 10000000.0;
bars.GetClose(bars.Count - 1) gets the close of the current bar. How is this different from the close parameter that is being passed into the OnDataPoint method?
Also: Is there a tutorial anywhere that explains how BarType classes work?

Comment