<p>I would say that the depth feed you are reading is of the orders coming in, <strong>before</strong> they are matched.</p>

<p>Those orders would feed into the matching engine which would make <em>fair</em> trades off those orders. </p>

<p>It is not possible to or desirable to make an optimal trade at any given instant. this can be due to network latency (etc)  and because someone might think it would be better to make a trade, that was slightly less than optimal, than to miss out on making a trade (but still not too much up or down);</p>

<p>For example:
What you will probably find is that if you put in an order to buy 10 btc at $100 but someone else has put in a sell order for 10 at  $99 you order will convert to a trade of $99. The buyer and the seller both get what they wanted. </p>

<p>Like wise if one seller was willing to sell 5 btc at $95 and someone else was willing 5 btc at $100 you would end up with 2 partial fills to complete the trade.</p>

<p>Back in the day on stock markets (i.e., not btc) the exchange (or broker) would just pocket the difference. However this doesn't really happen much now (in my understanding) as the markets are more efficient (fast traded data feeds &amp; order placement + high liquidity) </p>

<p>At the end of the day both buyers and sellers get what they want, and because there is reasonable liquidity, speed and fast access to market information, people will not be making trades which are too different from what would be optimal.</p>

CC BY-SA 3.0
2013-10-20T03:37:35.807Z
2013-10-20T03:48:17.103Z
2013-10-20T03:48:17.103Z
DarcyThomas
<p>caling getDepth.php I stumbled on some data that contains bids that are higher than asks. That can be seen in orderbook data with the following unix timestamps (for getting human readable date use $date -d@[unixtime]):
1325249854
1325249914
1325249975
1325319825
1325441984
1325545019
1325595982
1325597938
1325625735
1325645568
1325660473
1326656827
1328089365
1328089676
1328089737</p>

<p>So does MtGox stream "orders as arrived" without any processing or is this some kind of anomaly? From 6. 2011 till 9. 2012 with about 3min resolution I counted around 300 instances of such anomalies. Any thoughts on what could be going on? Is this common for other exchanges?</p>

<mtgox>
mtgox max bid higher than min ask
trytt
# mtgox max bid higher than min ask

(Asked by: username_0 on 2012-11-01)

caling getDepth.php I stumbled on some data that contains bids that are higher than asks. That can be seen in orderbook data with the following unix timestamps (for getting human readable date use $date -d@[unixtime]):
1325249854
1325249914
1325249975
1325319825
1325441984
1325545019
1325595982
1325597938
1325625735
1325645568
1325660473
1326656827
1328089365
1328089676
1328089737

So does MtGox stream "orders as arrived" without any processing or is this some kind of anomaly? From 6. 2011 till 9. 2012 with about 3min resolution I counted around 300 instances of such anomalies. Any thoughts on what could be going on? Is this common for other exchanges?

**Tags:** mtgox


---

## 1 answers

### Answer by username_1 on 2013-10-20. Score: 1

I would say that the depth feed you are reading is of the orders coming in, **before** they are matched.

Those orders would feed into the matching engine which would make *fair* trades off those orders.

It is not possible to or desirable to make an optimal trade at any given instant. this can be due to network latency (etc) and because someone might think it would be better to make a trade, that was slightly less than optimal, than to miss out on making a trade (but still not too much up or down);

For example:
What you will probably find is that if you put in an order to buy 10 btc at $100 but someone else has put in a sell order for 10 at $99 you order will convert to a trade of $99. The buyer and the seller both get what they wanted.

Like wise if one seller was willing to sell 5 btc at $95 and someone else was willing 5 btc at $100 you would end up with 2 partial fills to complete the trade.

Back in the day on stock markets (i.e., not btc) the exchange (or broker) would just pocket the difference. However this doesn't really happen much now (in my understanding) as the markets are more efficient (fast traded data feeds & order placement + high liquidity)

At the end of the day both buyers and sellers get what they want, and because there is reasonable liquidity, speed and fast access to market information, people will not be making trades which are too different from what would be optimal.


---

