Fills and slippage
Backtest and paper fills are simulated. The engine sets each fill price from a model, with measured-spread slippage and a configurable latency, so a simulated fill can sit at a price that never printed on the exchange. A live fill is the exchange's own, and live instances have no fill settings.
Where to set it
In the Backtester, open Settings and find Fills and fees. Those values are the defaults for every run, and each run can override them in the Engine & execution card of the backtest setup. Paper has its own page under Paper, Settings, which applies to running and new instances.
Slippage
Slippage is the price a taker gives up when its order crosses the spread. The Slippage setting has three choices:
- Measured spread is the default. A taker fill pays half the measured spread, or about 1 tick when the data has none. See Spread.
- Flat ticks charges a set number of ticks on every taker fill, 2 by default, and ignores the spread.
- Off gives frictionless taker fills. It isolates strategy logic and is not a realistic result.
Makers and takers
A taker is a market order or a triggered stop, and it pays slippage. A maker is a resting limit order. It sets its own price, so it never pays slippage. Each side pays its own fee rate, see Costs and fees.
Stops
A stop order fills in full, as a market order, once price reaches its level, and it is never split into partial fills. A stop the market gapped past fills at the next real tick, and slippage applies from there. A print exactly at the stop fills at the stop. On 1s and 1m data, a level jumped between two bars fills at the next bar's open.
Limit orders
A limit order placed with the market already at or past its price fills at once, at the limit or better, and never worse than the limit. This holds in the Through N ticks mode. A limit on the passive side rests and fills at its level as a maker. How a resting limit clears is the Limit fill setting, see Limit fills and queue lots.
Intra-bar race
When a stop and a target both sit inside one 1s bar, the Intra-bar race decides which is reached first. Dip first is the default: a bullish bar visits its low first, so a long's stop wins over its target. High-first and Low-first are the alternatives. The setting applies to 1s runs only.
Not simulated yet
- Order-book (level 2) data, and a queue simulation built on it, are coming.
- The fill rule draws no random numbers.
Related: Latency and Market impact.