Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Series<T> with multi timeframe

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

    Series<T> with multi timeframe

    Hi,

    [Note - I have accidentally posted this in the Nt7, not 8 forum! Sorry - Could not figure out how to delete it]

    I have a chart that can be any time period, but I also add some additional data series to them for the indicator. All those additions are 30 second series.

    I want to add a Series. This will hold a calculation of 2 or more of the 30 second data series values. When I do this though, the Series only matches the barcount of the main data series, which could be anything.I've read through the docs, but am missing something....

    How can I use a data series with a 30 second period, to match the additional data series rather than the primary user added one that is charted?

    For example

    AddDataSeries("VOL", Data.BarsPeriodType.Second, 30, Data.MarketDataType.Last);

    and I have

    volseries = new Series<double>(this, MaximumBarsLookBack.Infinite);

    The main series for example may be a 900 tick chart. The volseries will be created with that bar array. I want it created based on the adddataseries array. Is this possible? It looked in the docs you could pass a 'Bars' object, but I could not get it to work.

    I could just use a double[] instead, but then some of the NT functions I was using are no longer usable.

    Thanks.

    #2
    OK, please ignore - Finally figured it out. Found I can pass BarsArray[dataseries], so working OK now.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by TraderBCL, Today, 04:38 AM
    3 responses
    23 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Started by WeyldFalcon, 08-07-2020, 06:13 AM
    11 responses
    1,423 views
    0 likes
    Last Post jculp
    by jculp
     
    Started by RubenCazorla, Today, 09:07 AM
    0 responses
    4 views
    0 likes
    Last Post RubenCazorla  
    Started by BarzTrading, Today, 07:25 AM
    2 responses
    29 views
    1 like
    Last Post BarzTrading  
    Started by devatechnologies, 04-14-2024, 02:58 PM
    3 responses
    21 views
    0 likes
    Last Post NinjaTrader_BrandonH  
    Working...
    X