Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Current Bid Ask Pressure Indicator

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

    Current Bid Ask Pressure Indicator

    Hi,
    I am trying to build an indicator, which shows the current pressure at the ask and the bid and cumulates that volume until the inside market moves up or down and then does the same at the new pricelevels(bid and ask). I figured out several ways to get cumulative volume at price(onMarketData), but how can i reset that, when the inside market moves. I cannot figure out, how to program the change of position of the inside market;

    #2
    Hello Keepsimple,

    Thank you for your post.

    To clarify a couple points, are you looking for when a new bar is created and to reset your values?
    Are you wanting to get the market depth or just the one level at the bid and ask prices?
    Cal H.NinjaTrader Customer Service

    Comment


      #3
      Hi,
      thanks for quick reply.
      Not a new bar, but a change of the current bid and ask price, nothing to do with bars.
      As long the current bid ask prices stay the same I want:
      a. cumulative traded volume at the ask
      b. cumulative traded volume at the bid
      if bid ask prices move up or down
      restart from zero with cumulation.
      I know how to cumulate traded volume at price, but i do not know, how to program a change in bid ask levels, which whould be the condition to reset cumulative volume.

      Attached picture shows position of inside market (blue box), I want cumulative vol at a and b, til inside market moves up or down and then restart cumulation at bid and ask.
      Attached Files
      Last edited by keepsimple; 09-19-2014, 09:32 AM.

      Comment


        #4
        Keepsimple,

        You would want to use a double variable to store the ask price and one for the bid price

        You can then check if the ask or bid is equal to the variable to add that volume to the accumulation.
        If not equal, this where you would reset the volume variable.
        Cal H.NinjaTrader Customer Service

        Comment


          #5
          Thanks again,
          yes, that might work,
          will try and post back afterwards.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by elirion, Today, 01:36 AM
          2 responses
          12 views
          0 likes
          Last Post elirion
          by elirion
           
          Started by DJ888, 04-16-2024, 06:09 PM
          5 responses
          14 views
          0 likes
          Last Post NinjaTrader_Erick  
          Started by samish18, Yesterday, 08:31 AM
          4 responses
          14 views
          0 likes
          Last Post elirion
          by elirion
           
          Started by funk10101, Yesterday, 09:43 PM
          1 response
          14 views
          0 likes
          Last Post NinjaTrader_Gaby  
          Started by TheWhiteDragon, 01-21-2019, 12:44 PM
          5 responses
          551 views
          0 likes
          Last Post NinjaTrader_ChelseaB  
          Working...
          X