Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Add custom DataSeries with multiple values

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

    Add custom DataSeries with multiple values

    I'm trying to add custom series to my strategy, but some of these series have multiple custom values.

    I'm currently using

    Code:
    AddDataSeries((BarsPeriodType)14, 10);
    as an example, but it's only allowing me to use one period/value.

    If possible, how do I adjust that to work properly? Any help is appreciated.

    Thanks

    #2
    Hello Lumbeezl,

    Thank you for your post.

    You can specify optional BarsPeriod values (such as Value2) of a custom BarsType in the BarsPeriod object initializer.

    For example:

    Code:
    AddDataSeries(new BarsPeriod() { BarsPeriodType = (BarsPeriodType)14, Value = 10, Value2 = 20 });
    Please let us know if we may be of further assistance to you.

    Comment


      #3
      That's exactly what I was looking for. Thanks so much for the quick response

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by cmoran13, 04-16-2026, 01:02 PM
      0 responses
      75 views
      0 likes
      Last Post cmoran13  
      Started by PaulMohn, 04-10-2026, 11:11 AM
      0 responses
      43 views
      0 likes
      Last Post PaulMohn  
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      167 views
      1 like
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      101 views
      1 like
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      165 views
      2 likes
      Last Post CaptainJack  
      Working...
      X