AI QuantAll research examples

Backtested research example

Cost-Aware Selective Extrema Crypto Timing

ML_COST_AWARE_SELECTIVE_EXTREMA_TIMING
cryptominute-dataohlcv-onlymachine-learningwalk-forwardlocal-extremacost-awareselective-abstentionlong-onlynext-bar-execution

🗓 Backtest period: 2020-01-01..2025-10-08

Backtest metrics

Sharpe
0.00
Total Return
0.0%
Max Drawdown
0.0%
CAGR
0.0%
Volatility
0.0%
Trades
0

Strategy Card

Cost-Aware Selective Extrema Crypto Timing — strategy card

Spec ID: spec-cost-aware-selective-extrema-crypto-1784918823 · Generated: 2026-07-24 19:12 UTC

Cluster: Ml Timing · Sub Cluster: Cost-Aware Crypto Extrema Timing

One-line description

Long-only spot crypto timing model that enters selectively when ML forecasts indicate a probable local minimum, positive 4h net edge after costs, and low local-maximum risk. Positions exit on stop, target, timeout, adverse extrema risk, or expected-edge reversal.

Why this trade exists

Crypto markets can exhibit short-horizon mean reversion around local extrema, driven by liquidity shocks, forced flows, retail overreaction, and fragmented 24/7 market structure. The strategy attempts to monetize rebounds after statistically identifiable local lows while avoiding periods where the next local high or insufficient post-cost edge is likely.

The core hypothesis is not that every predicted trough is tradable, but that a calibrated, cost-aware abstention policy can filter for only the rare extrema events with enough expected 4h edge to survive spread/fee/slippage assumptions. Walk-forward retraining and calibration are used to reduce static-regime overfit, while long-only spot constraints avoid borrow and funding assumptions.

Algorithm

[code omitted from public view]

Parameters

Param Value Notes
Universe Top 10 crypto by 1y dollar volume Long-only spot universe
Data 1-minute OHLCV, resampled to 5min primary and 1h secondary No synthetic execution prices; skip missing execution bars
Backtest window 2020-01-01 to 2025-10-08 Walk-forward monthly test folds
Initial training 18 months from 2020-01-01 Monthly retraining
Calibration 3 months Thresholds selected on calibration fold only
Label horizon 4h Forward return from next executable open to 4h-later open
Local extrema labels 40 bps min pullback/rebound Centered extrema; radius 48 bars on 5min and 4 bars on 1h equivalent
Features 96-bar lookback Return lags, volatility, range, volume z-scores/spikes, price location, distance to highs/lows, VWAP-proxy deviation, time features
Models HistGradientBoostingClassifier + ExtraTreesRegressor Balanced classifier weights; isotonic calibration; ExtraTrees with 300 trees
Entry thresholds p_min grid 0.60-0.85; net-edge grid 21-100 bps Selected by calibration net return after costs
Entry cost hurdle 31 bps primary round trip Stress grid: 21, 31, 51 bps
Entry risk filter maximum-risk probability < 0.35 Avoid predicted local highs/adverse regimes
Exit rules -75 bps stop, +120 bps target, 48-bar timeout Also exit on max-risk probability >= 0.55 or expected edge <= 0
Position sizing Equal-weight capped Max 10% NAV per symbol; max 3 concurrent positions
Leverage Max 4.0 configured; no borrowing enabled Entries skipped or resized to fit constraints
Execution Next resampled bar open Signal after completed bar; model exits also next bar open
Costs 31 bps primary round trip, half per side Terminal liquidation cost included; separate broker commission fields also present

Look-ahead audit

# Concern Status
1 Centered local-extrema labels use future bars Acceptable for supervised label construction only; labels are purged/embargoed and not used as live features
2 Feature normalization leakage Mitigated: normalization fit on training fold only
3 Threshold overfit to test data Mitigated: threshold selection uses calibration fold only, with test fold held out
4 Forward-return label overlap across splits Mitigated: 4h purge horizon and embargo by bar after split
5 Execution timing Mitigated: signals generated after completed resampled bar and executed only at next bar open
6 Missing or synthetic prices Conservative: no synthetic execution prices; trades skipped or exited when required execution price is unavailable

Caveats / known limitations

Results

The current backtest summary is effectively a no-trade result: total return, Sharpe, Sortino, Calmar, volatility, drawdown, win rate, profit factor, VaR/CVaR, and average win/loss are all reported as 0 because the run generated 0 trades across 0 symbols. This should be treated as an implementation or gating outcome rather than evidence of alpha; the next research step is to verify universe loading, policy-gate pass rates, calibration trade counts, and threshold strictness.

Backtest metrics snapshot

Metric Value
Total Trades 0
Symbols 0

Backtests are historical simulations for research purposes only. They are not investment advice and do not guarantee future performance.