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 charlesugo_1, 05-26-2026, 05:03 PM
      0 responses
      56 views
      0 likes
      Last Post charlesugo_1  
      Started by DannyP96, 05-18-2026, 02:38 PM
      1 response
      143 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 05-11-2026, 05:56 AM
      0 responses
      160 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 05-10-2026, 08:12 PM
      0 responses
      96 views
      0 likes
      Last Post CarlTrading  
      Started by Hwop38, 05-04-2026, 07:02 PM
      0 responses
      276 views
      0 likes
      Last Post Hwop38
      by Hwop38
       
      Working...
      X