Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Referencing timeframe

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

    Referencing timeframe

    Hi guys.

    Is there a way to reference the time frame chosen in a strategy? I need it so I can create my secondary bars time-frame as I work in multiples of 3. For example if primary bars is selected as 1500 tick then secondary bars needs to be 500 tick. For example what I am trying to do is this.
    Initialize
    {
    eg. Add(PeriodType.Tick.PrimaryBars / 3);
    }

    Thanks

    Ash

    #2
    Hi Ash, unfortunately we could not support the dynamic addition of series - you can query the series you're working with over the BarsPeriod.Id and Value, however only outside of Initialize().

    For your need, I would create custom inputs for the series to load, so the user sets the timeframe to a third as needed via the input.

    Comment


      #3
      Cheers for the response Bertrand. Good idea, I will just create user inputs for the time frames as suggested.

      Thanks

      Ash

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      67 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      36 views
      0 likes
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      59 views
      1 like
      Last Post CaptainJack  
      Started by CarlTrading, 03-30-2026, 11:51 AM
      0 responses
      62 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 03-30-2026, 11:48 AM
      0 responses
      53 views
      0 likes
      Last Post CarlTrading  
      Working...
      X