Backtesting
Backtesting assumptions and troubleshooting
Learn how candle-based fills, volume limits, fees, slippage, and account accounting shape results.
Backtesting is deterministic candle simulation. It cannot reproduce every price path, queue, or broker rule.
Fill and candle assumptions
Orders become eligible on the next execution candle. Market orders fill at the next candle open. Limits can receive a better open after a gap; stops use the worse open after a gap and configured adverse slippage. A stop-limit first triggers at its stop, then waits for its limit. Conservative mode visits the adverse extreme first for the current position; optimistic mode visits the favorable extreme first. OHLC path estimate visits the nearer high/low first, then the other extreme and close. If stop and target are both touched, this path determines which is first.
The volume participation cap is shared across fills on a candle. Missing or invalid volume is uncapped and adds a warning. Fees apply per fill; slippage applies to market and stop-market fills, not limit fills. Accounting uses one net position and linear quantity-times-price P&L. It does not model contract multipliers, currency conversion, borrow or funding, maintenance margin, or broker liquidation. Futures and indexes without contract specifications are proxies.
If a session cannot be created
Check symbol support, date order, provider limits, and returned candle count. Shorten the range or use a coarser interval. Review warnings and coverage before treating the report as complete. For metric definitions see results.