validate_strategy
Run statistical validation on a trading strategy using DSR, walk-forward, regime analysis, and CPCV to detect overfitting and assess performance across market conditions.
Instructions
Validate a trading strategy using statistical tests (DSR + Walk-Forward + Regime + CPCV).
For educational and research purposes only. Not financial advice.
Upload a trade log CSV (QuantConnect format) or daily returns CSV. The tool runs four statistical tests:
Deflated Sharpe Ratio (DSR) — detects overfitting from multiple testing
Walk-Forward Validation — checks out-of-sample consistency
Regime Analysis — performance across bull/bear/crisis markets
CPCV — cross-validated Sharpe stability across time periods
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| format | No | CSV format — "quantconnect" for trade logs (columns: Entry Time, Exit Time, Direction, Entry Price, Exit Price, Quantity, P&L, Fees, IsWin) or "returns" for daily returns (columns: date,return or single column of returns). | quantconnect |
| file_path | Yes | Absolute path to the CSV file on your local machine. | |
| strategy_name | No | Name of the strategy (for the report). | |
| num_strategies | No | How many strategies you tested before picking this one. Higher M = stricter DSR threshold (corrects for selection bias). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||