Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Working with Market Depth

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

    Working with Market Depth

    Hi all,
    I'm trying to analyze what happens on the ladder across various instruments, so I started recording marketdepth events through ninja.

    What I don't understand is how the process of registering the events works:
    1) Operation "Insert" means a NEW Bid/Offer has been put on the ladder where previously was "blank"
    2) Operation "Update" means the Volume of Bid/Offer is updated where there was already a Bid or an Offer
    3) Operation "Remove" ? This should tell that a Bid/Offer has been pulled from the ladder but if I record this event it doesn't say which price was pulled.

    Can you please clarify? For your benefit please see below a quick extract of market depth this morning of 6A

    A;07/03/2013;08:14:29;29;0;Ask;Update;1.0245;28
    6A;07/03/2013;08:14:29;29;0;Bid;Update;1.0244;34
    6A;07/03/2013;08:14:29;29;0;Ask;Update;1.0245;27
    6A;07/03/2013;08:14:29;29;0;Bid;Update;1.0244;35
    6A;07/03/2013;08:14:29;29;0;Ask;Update;1.0245;16
    6A;07/03/2013;08:14:25;25;0;Ask;Update;1.0246;61
    6A;07/03/2013;08:14:29;29;0;Ask;Update;1.0245;6
    6A;07/03/2013;08:14:29;29;0;Ask;Remove;0;0
    6A;07/03/2013;08:14:29;29;0;Ask;Insert;1.025;175
    6A;07/03/2013;08:14:29;29;0;Bid;Remove;0;0
    6A;07/03/2013;08:14:29;29;0;Bid;Insert;1.0241;136

    #2
    Hello phi3zz0,

    You are understanding is correct of all of the Operations. When the Operation.Remove is called it will not tell you the Price but it will tell you the Position. For example most Market Depth on Instruments will be 5 (numbered 0-4) in either direction, and when a Remove it called it will tell what Position it is removing. So here would be a sample output.

    Remove
    Price: 0 Position: 4 MarketDataType: Bid
    Insert
    Price: 1.0247 Position: 4 MarketDataType: Bid

    You may view the following sample indicator for an example on how the OnMarketDepth() method functions.


    Note that if you want to know what price was removed, you can create a Level II book that will hold all of this information and when the Position has been marked as removed you can see which position was removed if you like.
    Last edited by NinjaTrader_JC; 03-07-2013, 08:23 AM.
    JCNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    67 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    36 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    60 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    62 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    53 views
    0 likes
    Last Post CarlTrading  
    Working...
    X