Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to get current bid/ask size

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

    How to get current bid/ask size

    Hello, I am trying to implement a scaling system to my strategy, is there any way to get the bid/ask size at a given moment? Eg. bid = 22 @ 100, ask = 13 @ 100.25? I do not want traded volume, but instead existing limit orders at the bid and ask. Thanks.

    #2
    Hello rbeckmann05,

    GetCurrentAskVolume() and GetCurrentBidVolume() would return the ask and bid size (as shown in ChartTrader or the SuperDOM).



    From my understanding, the ask and bid volume is the best price and number of shares waiting at that price, while the last volume would be the volume of most recent transactions.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea, so I came across that function when I was trying to impliment what I want, however it was giving me values in the 10s - 100s of thousands of contracts when entering. The code is very simple too, not sure how it would go wrong: EnterLong((int)GetCurrentAskVolume()). Any ideas?

      Comment


        #4
        Hello rbeckmann05,

        Is it a high volume instrument?

        Are you printing the value and comparing this to the ask and bid in chart trader?

        Are you sending a lot of orders?

        May I have you provide the output from printing order.ToString() in OnOrderUpdate()?
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Hi, sorry for late reply. Yes it is a high volume instrument, NQ and ES, however not high enough to have a bid/ask resting volume in the tens of thousands. When I print the volume it has the same effect. Not sending lots of orders, it enters once per day. I'm going to try it on a different, intraday strategy and see if it has the same results. If so, I'll send over those print statements

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Mindset, 04-21-2026, 06:46 AM
          0 responses
          87 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by M4ndoo, 04-20-2026, 05:21 PM
          0 responses
          128 views
          0 likes
          Last Post M4ndoo
          by M4ndoo
           
          Started by M4ndoo, 04-19-2026, 05:54 PM
          0 responses
          65 views
          0 likes
          Last Post M4ndoo
          by M4ndoo
           
          Started by cmoran13, 04-16-2026, 01:02 PM
          0 responses
          117 views
          0 likes
          Last Post cmoran13  
          Started by PaulMohn, 04-10-2026, 11:11 AM
          0 responses
          67 views
          0 likes
          Last Post PaulMohn  
          Working...
          X