Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Multi-Series Strategies - Live vs. Historical

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Originally posted by NinjaTrader_Bertrand View Post
    molecool, to clarify better what you're running into -

    'For example if I'm looking back at the past few 60-min candles and it's 17:05 right now'

    So you would be comparing MultiSeries access results here realtime vs historical?

    The difference would be descriebed in our MultiSeries environment docs under 'how bar data is referenced' - http://www.ninjatrader.com/support/h...nstruments.htm

    Summing this up - 'The point is if you have a multi-time frame script in real-time and it is processing tick by tick instead of on the close of each bar, understand that the OHLCV data you access in real-time is different than on historical data.'

    If you're seeing cases where an incorrect event sequence / bar data reference is used in historical mode only, then we would need a simplified and reproducible code example to look into matters.

    Thanks,
    NO that does not appear to be my problem. What's happening is that my price patterns run on long term intervals (i.e. 60-min or 360-min). Let's for instance take an example - a gapping candle that opens one tick or more above the previous close. Now in live mode I would look at the previous candle and do this:

    Opens[1][0] != Closes[0][1]

    So at the very first tick of the new hourly candle we would look at whether the previous candle's close (i.e. the 60-min candle) does not equal the open of the tick series.

    However in historical mode this changes because the current hourly candle (still in progress) does not exist yet until the hour completes. So I have to do this instead:

    Opens[1][0] != Closes[0][0]

    That seems to work for me now in historical mode. The entries are now being pinned on the right candle.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    663 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    376 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    110 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    575 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    580 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X