public OHLCBars(NinjaTrader.Data.IDataSeries o, NinjaTrader.Data.IDataSeries h, NinjaTrader.Data.IDataSeries l, NinjaTrader.Data.IDataSeries c) { opens = o; highs = h; lows = l; closes = c; update(); }
public InputBars(NinjaTrader.Data.IDataSeries i) { input = i; opens = input[0]; closes = opens; highs = opens; lows = opens; }
public static OHLC createPrimary(PrimaryOHLC type, NinjaTrader.Data.IDataSeries o, NinjaTrader.Data.IDataSeries h, NinjaTrader.Data.IDataSeries l, NinjaTrader.Data.IDataSeries c, NinjaTrader.Data.IDataSeries inp) { OHLC ans = null; switch (type) { case PrimaryOHLC.BARS: ans = new OHLCBars(o, h, l, c); break; case PrimaryOHLC.INPUTS: ans = new InputBars(inp); break; } return(ans); }