Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

IQFeed Data

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

    IQFeed Data

    Hi there

    I contacted IQFeed support and they say that they provide historical data as seen in the screenshot attached (for ES).

    The question: how can I access the info whether any historical tick was executed at the bid or the ask price via Ninjascript? Does Ninjatrader store this info at all so it is accessible for indicators/strategies?

    Thanks for clarifying!

    Cheers,
    Chris
    Attached Files

    #2
    Hello Diderino,

    Thank you for your post.

    This data is stored in the historical database when requested from the data provider.

    You can access the data in NinjaScript. Below is an example of checking if the tick is at the bid or ask:
    Code:
    		protected override void Initialize()
    		{
    			Add("ES 06-15", PeriodType.Tick, 1, MarketDataType.Ask);
    			Add("ES 06-15", PeriodType.Tick, 1, MarketDataType.Bid);
    		}
    
            protected override void OnBarUpdate()
            {
    			if(Closes[0][0] == Closes[1][0])
    				Print("ASK");
    			else if(Closes[0][0] == Closes[2][0])
    				Print("BID");
            }
    For information on multiple bar series 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.

    Comment


      #3
      That's what I am struggling with, as the MarketDataType.Bid and MarketDataType.Ask dataseries (1 Tick series as in your code) return 0 values for closes, while for the MarketDataType.Last it worked... any idea?

      Comment


        #4
        Hello Diderino,

        Thank you for your response.

        Can you provide the code you are using? And in addition can you provide the instrument you are testing this on and who you connect to for data?

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Hwop38, 05-04-2026, 07:02 PM
        0 responses
        160 views
        0 likes
        Last Post Hwop38
        by Hwop38
         
        Started by CaptainJack, 04-24-2026, 11:07 PM
        0 responses
        308 views
        0 likes
        Last Post CaptainJack  
        Started by Mindset, 04-21-2026, 06:46 AM
        0 responses
        245 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by M4ndoo, 04-20-2026, 05:21 PM
        0 responses
        349 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Started by M4ndoo, 04-19-2026, 05:54 PM
        0 responses
        179 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Working...
        X