Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Check instrument type in AddDataSeries

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

    Check instrument type in AddDataSeries

    I can see in the NT8 help guide how to check the MasterInstrument instrument type. But, what if I want to check the instrument type of one added data series added using AddDataSeries?

    Thanks

    #2
    Hello guillembm,

    Thanks for your post.

    You can access through the BarsArray[n].Instrument.MasterInstrument.InstrumentType where n = the data series. Here is an example you can test with:

    Print ("BIP: "+BarsInProgress+" Type: "+BarsArray[BarsInProgress].Instrument.MasterInstrument.InstrumentType);

    Example output:
    BIP: 0 Type: Future
    BIP: 1 Type: Future
    BIP: 2 Type: Forex
    BIP: 0 Type: Future
    BIP: 1 Type: Future

    Reference: https://ninjatrader.com/support/help...rumenttype.htm

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    86 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    48 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    29 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    32 views
    0 likes
    Last Post TheRealMorford  
    Started by Mindset, 02-28-2026, 06:16 AM
    0 responses
    67 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Working...
    X