• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

I need to Add() another Bars object to the same instrument

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

    I need to Add() another Bars object to the same instrument

    I need to add to the same instrument, another Bars object, where only changes "marketDataType".
    For example I want to add all bid data to the script. According to NT help guide, this should go like this: Add(PeriodType periodType, int period). The problem with this is that doesn't allow "marketDataType" , so I can't add what I want.

    How can I solve this?
    by Add(string instrumentName, PeriodType periodType, int period, MarketDataType marketDataType) and under instrumentName put the same?

    Is there other any way to Add a simple Bid series ?
    I'd like to know which is best way to do this.

    Thanks

    #2
    Hello,

    If you want to just add the Ask or Bid for the instrument you could use the following:

    Code:
    Add(Instrument.FullName, PeriodType.Tick, 1, MarketDataType.Ask);
    or a string name:
    Code:
    Add("ES 12-15", PeriodType.Tick, 1, MarketDataType.Ask);
    This would Add the instrument as 1 tick Ask series.

    You could do the same for Bid choosing any Period and Interval you need.

    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by dadarara, Today, 12:18 PM
    0 responses
    6 views
    0 likes
    Last Post dadarara  
    Started by joemiller, Today, 07:33 AM
    0 responses
    7 views
    0 likes
    Last Post joemiller  
    Started by isnercrypto, Today, 06:42 AM
    0 responses
    4 views
    0 likes
    Last Post isnercrypto  
    Started by Coursocied67, Today, 04:02 AM
    0 responses
    5 views
    0 likes
    Last Post Coursocied67  
    Started by TheGameOfProbabilities, 07-18-2019, 06:56 AM
    7 responses
    37 views
    0 likes
    Last Post DaveS
    by DaveS
     
    Working...
    X