Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Positions Array Correspondence to BarsInProgress

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

    Positions Array Correspondence to BarsInProgress

    I have read some contradicting information regarding how to use the Positions Array.

    I have the following in my strategy:

    BarsInProgress = 0 --- Index (do not submit orders against)
    BarsInProgress = 1 --- Instrument 1 Ticks (submit orders here)
    BarsInProgress = 2 --- Instrument 1 Minutes
    BarsInProgress = 3 --- Instrument 2 Ticks (submit orders here)
    BarsInProgress = 4 --- Instrument 2 Minutes
    BarsInProgress = 5 --- Instrument 3 Ticks (submit orders here)
    BarsInProgress = 6 --- Instrument 3 Minutes

    How would I reference the Positions Array for Instruments 1, 2, and 3?

    Is it:
    Positions[0] -> BarsInProgress = 0
    Positions[1] -> BarsInProgress = 1
    Positions[2] -> BarsInProgress = 3
    Positions[3] -> BarsInProgress = 5

    Or is it:
    Positions[0] -> BarsInProgress = 0
    Positions[1] -> BarsInProgress = 1
    Positions[3] -> BarsInProgress = 3
    Positions[5] -> BarsInProgress = 5

    Thanks,

    kc

    #2
    The second one is how it would work.
    Josh P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by sjsj2732, Yesterday, 04:31 AM
    0 responses
    39 views
    0 likes
    Last Post sjsj2732  
    Started by NullPointStrategies, 03-13-2026, 05:17 AM
    0 responses
    290 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    289 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    135 views
    1 like
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    96 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Working...
    X