PDA

View Full Version : Is Opens[i] enough to identify data series?


binwang2
09-17-2009, 01:44 PM
Hi NT experts,

For the same instrumnet with different time frames, I assume Opens[i][GetBar(datetime)] is enough to specify Open price of data series i at datatime.

However, I found I need to specify both BarsInprogress == i and Opens[i][GetBar(datetime)] in order to pin down the value. Otherwise, the Open[i][GetBar(datetime)] changes over time if i is not primary dataseries 0.

I am not sure if that has to be the case. I think the very reason to have Opens vs Open is to specify dataseries. I might have missed something.

Any comments are welcome.

NinjaTrader_Josh
09-17-2009, 02:06 PM
That is not the issue. The issue is GetBar(). GetBar() works based off of the BarsInProgress context you are in. If you are in 0, you get BIP0 returns. If you are in others, you get others.