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

The calculation of BlockVolume

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

    The calculation of BlockVolume

    Hello!

    since quite a while I am trying to figure out how blockvolume and orders in general are calculated and processed. You coded the platform so I think you can answer it best.

    My question is basically in what cases does Blockvolume get recognized and how exactly are order processed.
    For every buyer there is always a seller and vice versa. Will be both sides visible or just one? If just one, by which criteria does it select which side gets displayed, when several orders hit one bigger order like in the following exampel: Let's say there is a big 500 contract buy limit order that gets hit by 450 market sell orders. I guess in the tape this looks like 450 market sell orders, doesn't it? Since the blockvolume reads the 1 tick volume, I wonder if it gets the 500 buy limit at all? Are both, limit and market block orders, visible?

    Cheers

    #2
    Hello seykool,

    Thank you for the post.

    You can review the source code for BlockVolume in the NinjaScript editor, its under the Indicators folder.

    That uses some logic to calculate the volume based on the given modes being used so its a little more complex than the time and sales which simply checks if the incoming volume was greater than the block value you enter. The BlockVolume indicator uses the Volume series and not specifically ask/bid data. The volume is not split into buys/sells, its just the traded volume based on the given tick data.

    I look forward to being of further assistance.




    JesseNinjaTrader Customer Service

    Comment


      #3
      Hi Jesse!

      Thank you for the explanation. So then the question is of what is the Volume actually composed of? Is a volume of 2000, 2000 full contracts (rounds) or is it 2000 half contracts?
      My main question is, whether the blockvolume indicator detects block limit and market orders? No matter what the answer is, I am also really interested in the why.
      I looked inside the code and although I understood it at least almost, I would need more profound knowledge to conclude and answer my questions from above.

      Greetings

      Comment


        #4
        Hello seykool,

        The volume that the indicator uses would be from the bar series, that would be composed of the tick data volumes being provided by the data provider. I don't believe you would be able to determine the order type by using the indicator or bar series volume information, it would simply relay the amount of volume traded which meets the minimum block size you input.

        I look forward to being of further assistance.

        JesseNinjaTrader Customer Service

        Comment


          #5
          Hello Jesse,

          that's what I thought. The indicator takes the Volume from a one tick series which is from each trade. Therefore I wonder which type of orders it recognizes, since it might be (which is part of my question) that large limit orders get splited into all the market order that buy the limit order.
          If this is true, it only recognizes block market orders and limit orders get ignored??

          Greetings

          Comment


            #6
            Hello seykool,

            The volume which your script is seeing would not be broken into different types of orders, its just the traded volume for that instrument which the data provider offers at the tick level. All types of orders would be in that volume, its the traded volume at that price/tick. The indicator uses some other logic to equate that to the chart bar series so it can be on a larger timerframe than 1 tick.

            Please let me know if I may be of further assistance.
            JesseNinjaTrader Customer Service

            Comment


              #7
              Hello Jesse,

              since you didn't answer my core question I went ahead and asked in another forum. However, nobody there seems to know the answer, and before this thread here I also asked a vendor who didn't tell me neither.
              Would you be so kind to tell which type of block orders are visible? Block limit orders only, block market orders only, or both block limit and market orders?

              Greetings!

              Comment


                #8
                Hello seykool,

                since you didn't answer my core question
                If you are not clear on something please utilize the forum here and post a follow up message. I can't know that you are having trouble with understanding a concept if you don't clearly explain that or follow up with further questions.

                Would you be so kind to tell which type of block orders are visible?
                The volume is just volume to the indicator it does not know what kind of order made that volume. This is what I had previously said, you wont know if it was market/limit etc, or even ask or bid because its its just bar Volume. You can see the quantity but that's all.

                You can take a look in the BlockVolume indicator to see how it works, it uses the Volume series. It specifically uses the GetVolume with an bar index based on how it works but that retrieves data from the Volume series which is just numbers of volume per bar.



                Block limit orders only, block market orders only, or both block limit and market orders?
                You wouldn't be able to discern that level of detail using the volume series. A Block volume is just volume that is greater than a predefined amount. I believe the nearest you could make to this with the available data would be to know if the volume was last ask or bid, you would have to monitor the realtime level 2 orderbook data. You can see an example of working with level 2 data here: https://ninjatrader.com/support/help...vel_ii_dat.htm

                Please let me know if I may be of further assistance.

                JesseNinjaTrader Customer Service

                Comment


                  #9
                  Hello Jesse,

                  I tried to make the question and ask again. Anyways thank you for your detailed answer!
                  All this what you wrote I understand and got it. Therefore I asked (previously) what is Volume in itself, in the processing, what is it constructed of? Is it like open interest double the actual contracts traded or is the finite amount, which would imply that blockvolume can only see market orders or maybe also only limit orders but not both. Like you said, the indicator only gets the bar volume from a 1 tick series, which shows the volume of 1 trade at a time.

                  If there is one big order that gets eaten up by many small orders this would never be one big volume amount in 1 single tick the indicator could recognize. If the volume is transacted double, however, like with open interest, the blockvolume indicator would get all the small orders as well as the one big order once it got eaten up.
                  So the question really is what does volume consist of? This would answer which kind of orders the indicator is able to recognize.

                  I hope you can tell me about what volume consists of, how orders get internally processed at the broker and then "emitted" as volume information.

                  Greetings!

                  Comment


                    #10
                    Hello seykool,

                    The volume that the BlockViolume indicator sees is the same that you see in a chart, it represents the bar volume. That is constructed based on the data you have. It depends on what type of chart you used, for example a 1 minute chart is constructed from minute data which would entail the volume being reported is the volume of minute data. There is no detail in that volume of what orders created it, just that it happened during that time.

                    Please let me know if I may be of additional assistance.

                    JesseNinjaTrader Customer Service

                    Comment


                      #11
                      Hi Jesse,

                      sure the indicator just gets the normal bar volume but it gets it from 1 tick which is one trade. So the actual question is whether one traded contract causes 2 ticks or only 1?

                      Greetings

                      Comment


                        #12
                        Hello seykool,

                        I wouldn't be able to comment on how the data provider may construct and provide the tick data, NinjaTrader works like a radio and for tick data it would see the tick event as sent by your provider.

                        The indicator does use a 1 tick series but that is so it can check and update the block volume at a 1 tick frequency. That's used in addition to the primary it is applied to which gives some benefit to how the indicator was programmed.



                        Please let me know if I may be of additional assistance.
                        JesseNinjaTrader Customer Service

                        Comment


                          #13
                          Hello Jesse,

                          well then I have to live with not knowing it for sure. I was so curious, it really bothered me for months.
                          Thank you for your answers, Jesse!

                          Seykool

                          Comment


                            #14
                            Hello again Jesse,

                            I observed the T&S for a while and came to the conclusion that the blockvolume indicator doesn't anything else than scanning the T&S for big entries, just like the T&S filter and blocksize option.
                            It appears that the T&S only shows market orders and never limit orders. Can you answer me this one? Does the T&S only show market orders that hit limit orders? I think so at least.

                            Greetings

                            Comment


                              #15
                              Hello seykool,

                              We wouldn't be able to discern what type of order created the volume from that context.

                              You are correct, the blockvolume indicator is simply checking if its larger than a target amount to be considered block volume. This is one of the more simple items because it is only 1 number greater than another number as the condition to be block volume, there are no other considerations taken. The volume data simply does not contain the order information to know what made up the volume.

                              For any more detailed information about the changing data you would need to use the Level2 data. https://ninjatrader.com/support/help...=onmarketdepth

                              Please let me know if I may be of additional assistance.


                              JesseNinjaTrader Customer Service

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by llanqui, Today, 03:53 AM
                              0 responses
                              1 view
                              0 likes
                              Last Post llanqui
                              by llanqui
                               
                              Started by burtoninlondon, Today, 12:38 AM
                              0 responses
                              10 views
                              0 likes
                              Last Post burtoninlondon  
                              Started by AaronKoRn, Yesterday, 09:49 PM
                              0 responses
                              14 views
                              0 likes
                              Last Post AaronKoRn  
                              Started by carnitron, Yesterday, 08:42 PM
                              0 responses
                              11 views
                              0 likes
                              Last Post carnitron  
                              Started by strategist007, Yesterday, 07:51 PM
                              0 responses
                              14 views
                              0 likes
                              Last Post strategist007  
                              Working...
                              X