← All strategy prompts

Is my backtest just luck? Shuffle test and data-mining check

Before going live, make your agent shuffle your backtest trades to see the drawdown you should really expect, and check whether your 'edge' beats rules mined from random data.

stocksfuturescryptoeducationAny LLMAlpacaIBKR
✓ Published rules✗ Out-of-sample tested✓ Live vs paper disclosed✗ Reproduced by othersPreliminary

An education/audit prompt built from four cautionary posts. It doesn't trade.

Votes show community interest and never change Trust Scores or badges.

What they did

Four posts this week showed how a good-looking backtest can mislead. Derek reshuffled the order of his backtest trades many times. StatOasis mined 5,000 rules on SPY and compared the best with the best rule mined on zero-edge data. BacktestingMax ran 24 day-trading strategies against simply holding the index. Bernard the Autotrader shared a live book with a high win rate.

How it went

The posters' claims: Derek's backtest drawdown was 12%, but the median shuffled drawdown was 15% and the 95th percentile 26%, so he sizes and sets his stop-trading rule around 26%. StatOasis' best mined SPY rule made 11.2% a year, but the best rule on zero-edge data made 6.4%, so the real edge is closer to 4.8%. BacktestingMax: with $10,000 in 2024–25 after costs, holding ended at $14,350 versus $13,540 for the best day-trading strategy, which was ahead on only 52 of 502 days. Bernard: 257 live trades, 70% winners, yet −2.46% net on $100K, because the average winner was +0.02% and the average loser −0.08%.

All performance figures are the poster's or author's own claims. We haven't verified them.

Sources:

Worth knowing

The prompt

Fill in the [blanks], then paste it into any AI agent connected to your broker (see Brokers). Defaults: paper trading + approve every trade.

You are my backtest auditor. Do NOT place any trades.
Input: my backtest trade list [paste or attach CSV: date, P/L per trade] and how many rule variations I tried: [number].
1. Shuffle test: randomly reorder the trades [1,000] times. Report the median and 95th-percentile max drawdown versus my original drawdown. Recommend a position size so the 95th-percentile drawdown stays under [20]% of my account, and a 'stop trading and review' level.
2. Mining check: generate [same number of variations I tried] random-entry strategies with the same holding period and trade count on the same data. Report the best random result. Is my strategy clearly better?
3. Baseline: compare with buy-and-hold of [the traded asset] over the same period, and count on how many days my strategy's equity was ahead.
4. Win/loss shape: win rate, average win, average loss, and the break-even win rate implied by them.
End with a plain-English verdict: 'looks robust', 'needs more testing' or 'probably luck', with reasons.

SAFETY DEFAULTS (keep unless you deliberately change them):
- Analysis only: never place orders while running this audit.
- Before every order, show me: symbol, side, size, order type, limit price, stop, and the rule that triggered it. Then WAIT for my "approve".
- Hard limits: max [$500] per trade, max [3] open positions, stop all trading for the day after a loss of [$300].
- Log every signal, decision and fill to [a running log / spreadsheet] with timestamps.

Not financial advice. These are public strategies rewritten as prompts for education. Past or backtested results don't guarantee future returns. Prompt text is our own wording; source stories are credited above. Verified on 2026-10-25.