Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Multi instrument strategy help
Collapse
X
-
Multi instrument strategy help
I am wanting to combine instruments into a strategy but the example strategy SampleMultiInstrument is not enough for me to go off of. I should be able to set what instrument is being referenced or what instrument I am purchasing by setting the BarsInProgressIndex just as I would with Multi Time Frame, Correct? Also how can I reference commands like Close[0], High[0], Low[0] and Open[0] to a specific instrument and not just the primary?Tags: None
-
Hi Chris, correct BarsInProgress would let you know which bars index / instrument is calling the OnBarUpdate() method, for the order you need to be mindful the primary series will always be at 0, then your Add()ed ones will follow (per the order you have in the Initialize() Add calls).
For accessing bars data from other series, there's the MultiSeries variants of Close, High...etc as well, just add a s to them.
So would be then Closes, Highs, Lows and Opens
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by SalmaTrader, 07-07-2026, 10:26 PM
|
0 responses
50 views
0 likes
|
Last Post
by SalmaTrader
07-07-2026, 10:26 PM
|
||
|
Started by CarlTrading, 07-05-2026, 01:16 PM
|
0 responses
22 views
0 likes
|
Last Post
by CarlTrading
07-05-2026, 01:16 PM
|
||
|
Started by CaptainJack, 06-17-2026, 10:32 AM
|
0 responses
16 views
0 likes
|
Last Post
by CaptainJack
06-17-2026, 10:32 AM
|
||
|
Started by kinfxhk, 06-17-2026, 04:15 AM
|
0 responses
22 views
0 likes
|
Last Post
by kinfxhk
06-17-2026, 04:15 AM
|
||
|
Started by kinfxhk, 06-17-2026, 04:06 AM
|
0 responses
23 views
0 likes
|
Last Post
by kinfxhk
06-17-2026, 04:06 AM
|

Comment