GROK/DESK
← All guides

How to backtest AI trading setups before trusting them

Test every setup on 100+ days of one-minute data with real costs, judge it by profit factor and expectancy, then prove it in practice before it trades.

Write the setup as an exact rule

A setup must be precise enough for code to test: market, trigger, where the stop goes, a target at least four times the stop, and the hours it may trade. If you cannot write it down exactly, you cannot test it.

Use enough data, with costs

At least 100 days of one-minute data from your broker, including spread and commission on every trade. Small targets that look great without costs often lose money with them.

Judge the right numbers

Look at profit factor (gross wins divided by gross losses), expectancy per trade after costs, maximum drawdown and the worst trades — not the win rate alone. A high win rate with large losses can still lose money.

Watch for bias

Check the mix of buys and sells, the period tested and whether a few trades carry the whole result. A backtest that only works in one direction or one month is a warning, not an edge.

Practice before promotion

A setup that passes the backtest trades on paper first. Promote it to the demo account only after about 40 practice rounds with a profit factor of 1.5 or more and a positive last 20 rounds.

Want the complete setup?

Every prompt, file and command, step by step, in one course.

See the course