man touching screen of market trading candles

Posted by & filed under Blog, Forex articles.

Here’s a trick that works almost every time: take any scatter of dots on a chart, even dots placed completely at random, and given enough freedom in how you draw the line, you can bend a curve through every single one of them.

The line will look like a perfect fit. It will also tell you absolutely nothing about where the next dot is going to land.

That trick has a name — curve fitting — and it’s exactly what happens to a lot of trading strategies, just with pips instead of dots and an equity curve instead of a scatter plot.

A strategy with enough adjustable rules can be bent to match almost any historical price chart. The resulting backtest looks flawless. It just doesn’t mean what it appears to mean.

This is closely related to a topic covered in more technical depth elsewhere on this site — overfitting, which looks at the formal tests (walk-forward analysis, Monte Carlo testing, parameter sensitivity) that catch this problem statistically.

This article takes a step back and covers the same idea in its simplest, most visual form: what curve fitting actually looks like, why it’s so easy to do by accident, and a basic check you can run yourself before trusting any backtest.

The Idea, With No Trading Involved Yet

Imagine plotting ten random dots on a graph — genuinely random, no underlying pattern at all. A straight line drawn through them will miss most of the dots by some margin.

That’s honest: a straight line simply doesn’t have enough flexibility to chase every random wiggle, so it can only capture a broad trend, if one even exists.

Now let the line curve. Give it more bends — technically, more terms in the equation describing it. With enough bends, the curve can pass through every single dot exactly, no matter how randomly they were scattered.

Mathematically, a curve with enough flexibility can always be found to fit any finite set of points perfectly. That perfect fit is not evidence of a pattern. It’s evidence that you gave the curve enough freedom to chase the noise.

The practical problem shows up the moment an eleventh dot appears. The straight line, having never pretended to explain every wiggle, is often still roughly in the right area.

The elaborate curve, having been bent specifically to match the first ten dots and nothing else, frequently misses the eleventh dot by a wide margin — sometimes a worse margin than the plain straight line managed

. The flexibility that made it look so impressive on known data is precisely what makes it unreliable on new data.

Where the “Bends” Come From in a Trading Strategy

A trading strategy doesn’t look like a curve on a scatter plot, but it behaves the same way.

Every adjustable rule in a strategy — a moving average length, an RSI threshold, a stop loss distance, a session filter, a volatility cutoff — is another bend available to shape how the strategy reacts to a specific stretch of price history.

  • Few rules, little flexibility. A strategy with one or two simple conditions can’t bend itself around every quirk of the historical data. If it still performs reasonably well, that’s more likely to reflect something genuine.
  • Many rules, lots of flexibility. A strategy with a dozen conditions, filters and thresholds has enormous room to be shaped — deliberately or not — around the exact sequence of price moves in the data it was built on.
  • Tuning against the same chart repeatedly. Every time a parameter gets nudged because it made the backtest’s equity curve look a bit smoother, the strategy bends a little further toward that one specific chart, and a little further away from anything general.

None of this requires bad intentions. It’s simply what happens, by default, when a flexible set of rules is repeatedly adjusted against one fixed piece of history.

The curve gets better and better at describing the past, and nobody involved necessarily notices that it’s stopped describing anything general.

What a Curve-Fitted Equity Curve Tends to Look Like

You usually can’t tell curve fitting apart from a genuinely good strategy just by looking at the headline numbers — that’s what makes it a trap rather than an obvious red flag. But a few visual patterns in the backtest itself are worth a second look.

What you see Possible curve fitting More likely genuine
Equity curve shape Almost a straight diagonal line, barely any dips Visible ups and downs, realistic losing stretches
Number of rules/filters Many, each seemingly fine-tuned Few, each with an obvious market rationale
Reaction to a slightly different parameter Result changes drastically Result changes only a little
Performance on data added after the strategy was built Falls off sharply Broadly holds up

A Simple Visual Test Anyone Can Run

You don’t need statistical software to get a useful first read on whether a strategy has been curve fitted. This basic version takes a few minutes and catches a surprising number of cases.

  1. Split the backtest period roughly in half by eye — an earlier chunk and a later chunk of the same test.
  2. Look at the equity curve for the earlier chunk on its own. Does it look smooth and strong, the way the full backtest does?
  3. Now look at the later chunk on its own, especially if the strategy’s parameters were being adjusted while that later data was already visible. A curve-fitted strategy very often looks noticeably weaker in whichever portion of the data was effectively “seen” last, or more jagged and inconsistent than the earlier portion.
  4. Ask whether each parameter has a story. For every input the strategy uses, try to finish this sentence without mentioning the backtest: “this is set to this value because …”. If the only honest ending is “it made the backtest look better,” that parameter is a candidate for a bend fitted to noise rather than a reflection of anything in how the market actually behaves.

This eyeball version is deliberately rough, and it won’t catch everything — a strategy can pass this casual check and still be curve fitted in subtler ways.

For a properly rigorous version of the same idea — out-of-sample testing with a reserved hold-out period, walk-forward analysis, and Monte Carlo testing against random noise — see the companion article on overfitting in trading strategies, which covers exactly how to formalise this check before risking real money.

Key Takeaways

Given enough adjustable rules, almost any strategy can be bent to match almost any chart of historical prices. That perfect-looking fit says nothing about whether the strategy will work on prices that haven’t happened yet.

The simplest defence is scepticism toward strategies with a lot of finely tuned parameters and suspiciously smooth equity curves, and a basic habit of checking how a strategy performs on data that wasn’t available when its rules were set. Treat a flawless backtest as a question, not an answer.


This article is for educational purposes and does not constitute financial advice. Trading forex carries a high level of risk and may not be suitable for all investors.

Leave a Reply

Your email address will not be published. Required fields are marked *