Expand description
§Module: backtest::engine
Event-driven backtester with realistic fill simulation.
§Responsibility
Provides BacktestEngine which runs a list of Signals over
a BacktestConfig containing OHLCV bars, simulating fills at the
next-bar open with slippage and commission deductions.
§Guarantees
- Fills execute at next-bar open (no look-ahead on the signal bar)
- Slippage is expressed in basis points and applied symmetrically
- Commission is deducted per fill as a fraction of notional
- All equity curve values are non-negative
Structs§
- Backtest
Engine - Event-driven backtesting engine with realistic fill simulation.
- Backtest
Metrics - Summary performance metrics for a completed backtest.
- Backtest
Result - Full result of a
BacktestEngine::runcall. - Completed
Trade - A single closed round-trip trade.
- Engine
Config - Configuration for a
BacktestEnginerun. - Engine
Signal - A trading signal produced externally and fed into the engine.
Enums§
- Direction
- Direction of a trading signal.