Expand description
This module defines the structure that aggregates and stores all results produced during a trading backtest simulation.
It includes: Core performance metrics (returns, volatility, Sharpe, win rates, etc.). Options-specific metrics (return on margin, Greeks exposure). Detailed trade statistics and individual trade records. Full drawdown analysis (max drawdown, recovery times). Capital utilization data (capital usage, margin tracking). Time-series data for an equity curve, drawdowns, Greeks, and custom series. Optional metrics about market conditions (bull/bear days, volatility environment). Optional implied volatility tracking at trade times. Optional advanced risk metrics (VaR, Expected Shortfall, Ulcer Index). Optional Monte Carlo simulations for probabilistic risk and outcome analysis. General metadata: strategy name, test period start/end, initial/final capital, and space for custom metrics.
The BacktestResult struct is designed to fully capture all relevant information about how a strategy performed during a test, allowing deep analytics, reporting, and risk assessment.
Structs§
- Backtest
Result - Comprehensive container for all results generated during a backtest simulation.
- Simulation
Result SimulationResultrepresents the outcome of a financial or trading simulation, capturing the details of the simulation’s performance and metrics.- Simulation
Stats Result - Statistics aggregated from multiple simulation runs.