• 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

At Bid or at Ask?

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

    At Bid or at Ask?

    Hi there

    I added a 1 tick series to my indicator. I know how to get the price (close[0]) and the volume (volume[0]) of each tick. how do I find out, whether it was executed at the bid or ask price? getcurrentbid() substitutes the close price as it seems in case of historical data...

    thanks!
    Chris

    #2
    Hello Chris,

    Thank you for your post.

    You can add an additional series to your script for the Bid and Ask, you would then need to access that Bar Series to compare against the primary.

    To add the additional series in the Initialize() method please use the following as an example:
    Code:
    			Add("AAPL", PeriodType.Tick, 1, MarketDataType.Bid);
    			Add("AAPL", PeriodType.Tick, 1, MarketDataType.Ask);
    For information on historical bid and ask series please visit the following link: http://www.ninjatrader.com/support/h..._ask_serie.htm
    For information on multiple time frames in your code please visit the following link: http://www.ninjatrader.com/support/h...nstruments.htm

    Please let me know if I may be of further assistance.
    Patrick H.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Polo Trader, Today, 03:28 PM
    1 response
    11 views
    0 likes
    Last Post NinjaTrader_ChrisL  
    Started by Mykro, Today, 03:26 PM
    2 responses
    8 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by Polo Trader, Today, 03:14 PM
    3 responses
    22 views
    0 likes
    Last Post NinjaTrader_Tyler  
    Started by kantkant2, Today, 03:20 PM
    1 response
    6 views
    0 likes
    Last Post NinjaTrader_ChrisL  
    Started by Skyfly1715, Yesterday, 03:36 PM
    1 response
    22 views
    0 likes
    Last Post NinjaTrader_Marco  
    Working...
    X