Take the 2-minute tour ×
Quantitative Finance Stack Exchange is a question and answer site for finance professionals and academics. It's 100% free, no registration required.

I'm sure there is a simple answer to this but I haven't had any luck with searches. I'm just wondering when someone places a market order which order(s) from the limit order book are selected to fill that? Let's say the order book has the highest bid at 100 and the lowest ask at 101 and I place a limit order to buy at 100. I'm now bidding the same as all the other highest bids, so when market orders to sell come through get matched with highest bids, how are the bids selected? Is it random, in order by time, size, or some other mechanism?

And just in case it is by time like FIFO, let's say I placed many limit orders long in advance at prices well out of the money 99, 98, 97, etc. Could I get myself to the top of the list at all these prices that are out of the money just by placing my orders anticipating a possible drop?

share|improve this question
add comment

3 Answers 3

This is determined through order precedence rules. In most markets, these are

  1. Price priority: precedence goes to the best ask or bid offers.

  2. Time precedence: precedence goes to who improves the current ask or bid offers. In computer-speak that's FIFO. It encourages the market participants to improve prices aggressively.

  3. Public order precedence: public orders have precedence over hidden orders.

As I pointed out before, rules for some futures markets can be quite different (see this answer). The pro-rata allocation used in some futures markets is sometimes referred to as size precedence: when two or more orders are at parity (according to the enforced priority rules) orders fill in proportion to sizes.

Let me add that precedence across exchanges is determined by Regulation NMS. The NBBO (National best bid and offer) for a stock is the best bid or offer sent by a market center to the SIP (Security Information Processor). This best price has the precedence across exchanges, and market orders should be routed towards the venue which displays the NBBO. In practice this is hard to enforce (see Nanex on this and the now-banned flash orders).

share|improve this answer
add comment

All exchanges allocate to best price. This is by law in the US, and it's unimaginable that an exchange would do otherwise in other jurisdictions. As for tie-breaks, there are two possibilities for public orders:

  • Time: first-come first-served; used for most equities exchanges
  • Pro-rata: larger quote sizes get more of an incoming market order; common for futures and options exchanges, plus the PSX equities exchange

Once the public orders are exhausted at the best price, the exchange may fill hidden limit orders. (Note that not every exchange allows hidden limit orders.)

Some exchanges also incentivize the market maker who established the new best price. That is, in a pro-rata allocation, the market maker who has set a new price that becomes the best may receive a larger share of an incoming market order than normal.

Finally, some exchanges have parity rules. On the NYSE, for example, an order is usually allocated equally among the designated market maker, the first-come floor broker, and the first-come limit order from SuperDOT.

So it should be clear from the above that every exchange has its own rules for allocation; there is no one true path that every venue follows.

share|improve this answer
    
I knew about the NYSE DMM "parity" rule, but didn't realize it also involves the first-come floor broker order. Is it still the case? –  Robert Kubrick Apr 19 '12 at 21:26
    
@RobertKubrick Parity means the order is split among the DMM, floor broker, and DOT. All three share "equally". –  chrisaycock Apr 19 '12 at 22:03
    
I know, basically DMM and floor brokers have an unfair advantage compared to everybody else (DOT) because their time priority is only relative to other floor brokers. I thought the privilege was only granted to DMM "to maintain a fair and orderly market". –  Robert Kubrick Apr 20 '12 at 1:59
1  
@RobertKubrick Here's NYSE's own explanation of parity. –  chrisaycock Apr 20 '12 at 2:23
    
Thanks, it's very clear from the fact sheet that DMM and floor brokers have a time priority privilege. –  Robert Kubrick Apr 20 '12 at 13:12
add comment

As RYogi indicated, this depends on the exchange and product type.
e.g. here is a summary of the matching algorithms at the CME

The answer to the second part of your question is yes. Even in a market like the Eurodollar futures -- which is mostly pro-rata, but has a FIFO component -- a common strategy is to "stack the book." So that you will be first in queue. This usually involves hiring a night clerk to pull orders as the market moves. ;-)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.