Read the top of the book
The best bid is the highest displayed buying price and the best ask is the lowest displayed selling price in an order book. Their difference is the quoted spread. It describes the first visible price gap, not the full cost of executing every possible order size.
Follow the available size
Imagine asks of one unit at $100.00, two units at $100.10 and two units at $100.30. In a static simplified book, a market buy of four units would consume the first unit, the next two, and one unit at the third level. Actual books can change while an order is being processed.
Calculate the weighted average
The illustrative cost is 1 × 100.00 + 2 × 100.10 + 1 × 100.30 = $400.50. Divide by four units to obtain $100.125 per unit. The difference from the initial $100.00 best ask is $0.125 per unit, before fees. Using only the first displayed ask would understate this example’s cost.
Record the conditions
Execution analysis should state the order size, side, observation time and reference price. Slippage calculations vary with the chosen reference, so disclose it. A quote from a public price feed is not an executable instruction or a guarantee that the displayed depth will remain available.
WORKED EXAMPLE / EXPLICIT ASSUMPTIONS
A hypothetical four-unit buy
- 1 unit at $100.00
- $100.00
- 2 units at $100.10
- $200.20
- 1 unit at $100.30
- $100.30
- Total / quantity
- $400.50 / 4
- Average price
- $100.125
- Excluded
- Fees, latency and changing order-book conditions
Any numerical figures in an illustration are hypothetical and are not a quoted offer or execution result.
Practical checklist
- Record quantity as well as price.
- Use a weighted average across fills.
- Name the slippage reference price.
- Keep trading fees separate from price impact.
CHECK THE CONCEPT
Can you explain the distinction?
Further reading
Kraken: public market-data documentation ↗Use current provider or instrument documentation when applying a concept to a particular product.