Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

BarsInProgress

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

    BarsInProgress

    I would like to know what happens when an indicator is derived from another indicator which has many Time Series.

    Example :

    Indicator1 : Indicator
    Indicator 2 : Indicator1

    Indicator1 has 2 BarsArray (ProgressBar == 1 1 tick and ProgressBar ==0 30 minutes)
    Do I have to Add 1 tick period to Indicator2 if I don't need it...


    Thanks

    #2
    Hi blar58,

    Values generated from other series are available without having to add the series. The series, themselves are not available from the calling indicator unless you add them.

    Example.
    Indicator 1 calls Indicator 2

    Indicator 2 has added series and plots a value based on these added series. You can access the value of this plot from indicator 1, but not the series unless you add it.
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Ryan

      Here is my situation :

      Code:
      Indicator1 : Indicator
      
      Initialize()
      Add(PeriodType.Tick,1);
      
      OnBarUpdate()
           if(BarsInProgress ==1)
            indicator2OnMarketData(volume)
      
      
      Indicator2 : Indicator1
      Initialize()
      .....
      
      indicator2OnMarketData(volume)
      // do stuff
      Tick dataseries has been added to Indicator 1 only. When I called BarsInProgress == 1
      and I called a method that belongs to indicator 2 which has only the primary bar series
      does the indicator2OnMarketData(volume) method is being executed with tick data series ?

      Thanks

      Comment


        #4
        Indicator 2 offers only the BIP that the series is applied to, since no other series has been added. You can access values generated from Indicator 1, even if the values are based on another series.

        If you need to do calculations on other series within indicator 2 then all these series must be added.

        Attached are two scripts that illustrate this. Indicator 2 is getting a value that is derived from the added series in indicator 1. This is available, but the series itself is not available unless you add it.
        Attached Files
        Ryan M.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

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