Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Accessing multi-time frame data

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

    Accessing multi-time frame data

    I'm trying to develop an indicator (later using the same data structures in a strategy) that reads in both the last and ask data. I've learned to load both into my chart within the data series and overlay them so I can see them together. Now I'd like to access them within my indicator (strategy). But when I read about BarsArray, it says it can only access the data if I use AddDataSeries(). Is that true or can I access the data like Opens[index]?

    Secondly when I read about the BarsArray it says I can only access one at a time in separate iterations in OnBarUpdate(). But I want them all at the same time. Is that possible? I need to pass both the last and ask PriceSeries data to one of my addOns concurrently. Is this possible?

    #2
    Hello dweems,

    Yes you need to use AddDataSeries to be able to use the Opens or other plural multi series.

    To access all the timeframes at once you need to use the Plural series like Opens[1][0] that would be for the second series. OnBarUpdate is only called for 1 BarsArray at a time, that is the BarsInProgress property which denotes the series that called OnBarUpdate.

    Passing data to an addon is not something the platform has specific features for, that highly depends on what you mean by addon.


    JesseNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by unpronounceable1700, Today, 03:00 AM
    2 responses
    25 views
    0 likes
    Last Post unpronounceable1700  
    Started by unpronounceable1700, Today, 04:53 AM
    1 response
    26 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Started by ninza33, Today, 07:26 AM
    1 response
    16 views
    0 likes
    Last Post NinjaTrader_Zachary  
    Started by gyilaoliver, Today, 03:31 AM
    1 response
    9 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Started by RISKYBUSINEZZ, Yesterday, 09:09 PM
    2 responses
    14 views
    0 likes
    Last Post RISKYBUSINEZZ  
    Working...
    X