How to Optimise Indicator Settings Without Fooling Yourself

Tuning parameters is useful; tuning them until the past looks perfect is self-deception.

In short: Sound optimisation means finding settings that work robustly across many conditions and out-of-sample data, not the single best-performing setting on your historical sample — which is almost always a fluke that fails live.

Why optimise at all

Default settings like RSI(14) or MACD(12,26,9) are sensible starting points, not sacred numbers. Different instruments and timeframes have different rhythms — Bank Nifty is faster and more volatile than Nifty, so a setting tuned for one may be too jumpy or too slow for the other. Thoughtful optimisation asks whether a setting suits the character of what you trade. The danger is not optimisation itself but the seductive slide from 'find a setting that fits' to 'find the setting that would have been perfect'.

The single-best-setting trap

If you test hundreds of RSI periods on Nifty's last two years and pick the one with the highest return, you have almost certainly found noise, not signal. That exact setting fit the random details of that specific stretch of history and has no reason to keep working. The tell-tale sign is fragility: if RSI(11) was brilliant but RSI(10) and RSI(12) were poor, the result is a fluke. Real edges are broad — nearby settings should perform similarly.

In-sample and out-of-sample

The core discipline is splitting your data. Optimise on one portion (in-sample), then test the chosen setting on a separate portion the optimisation never saw (out-of-sample). If a setting that looked great in-sample also holds up out-of-sample, you have some evidence it captures something real. If it collapses out-of-sample, you overfitted. Without this split, every optimisation looks successful, because you are simply describing the data you tuned on.

Prefer robust plateaus over sharp peaks

When you chart performance across a range of settings, look for a broad plateau rather than a single sharp peak. A plateau — where many neighbouring settings all work reasonably — means the edge is stable and not dependent on a precise number you got lucky with. A lone spike surrounded by poor results is the signature of curve-fitting. Choosing a setting from the middle of a plateau is far safer than chasing the highest bar on the chart.

Change one thing at a time

Optimise deliberately, not by brute force over everything at once. Tuning the RSI period, its overbought/oversold levels, the trend filter and the stop simultaneously creates an astronomical number of combinations, and the best of them is guaranteed to be lucky. Fix most parameters at sensible values and vary one at a time, watching whether performance changes smoothly and understandably. If you cannot explain why a setting helps, be suspicious of it.

Account for costs and regime

Optimisation done without realistic costs is fantasy. Include brokerage, STT, slippage and the bid-ask spread, because a setting that trades often may look great gross and lose net — this matters especially for intraday Nifty and Bank Nifty strategies where costs accumulate fast. Also test across different regimes: a setting tuned only on a trending year will fail in a ranging one. Robustness across costs and conditions matters more than any peak return figure.

Key takeaways

  • Defaults are starting points; tuning to an instrument's character is legitimate.
  • The single best historical setting is almost always noise that fails live.
  • Split data into in-sample and out-of-sample to detect overfitting.
  • Choose settings from broad plateaus, not sharp isolated peaks.
  • Include realistic costs and test across regimes before trusting any setting.

FAQ

Should I change indicator settings from the defaults?
You can, if you have a reason — different instruments and timeframes have different rhythms. But defaults like RSI(14) are sensible, and changing settings should make an indicator fit the market's character, not just fit past data.
What is the danger of optimising indicator settings?
The main danger is overfitting: picking the setting that performed best on your historical sample. That setting usually fit random noise in that specific data and fails on new data.
What is in-sample and out-of-sample testing?
You optimise on one portion of data (in-sample), then test the chosen setting on a separate portion it never saw (out-of-sample). Holding up out-of-sample is evidence the setting captures something real.
Why should I prefer a plateau over a peak?
A broad plateau means many nearby settings work, so the edge is stable. A lone sharp peak surrounded by poor results is a sign of curve-fitting and luck.
How many parameters should I optimise at once?
Ideally one at a time. Tuning many parameters together creates huge numbers of combinations, and the best of them is almost guaranteed to be a lucky fluke rather than a real edge.
Do trading costs matter when optimising?
Very much. Brokerage, STT, slippage and spreads can turn a gross-profitable setting into a net loss, especially for frequent intraday Nifty and Bank Nifty trades. Always optimise with realistic costs included.
How do I know if I have overfitted?
Warning signs include a setting that works only at one exact value, results that collapse out-of-sample, and performance that depends on many jointly tuned parameters you cannot explain.
Is the default RSI(14) good enough?
For many traders, yes. The defaults are widely used and robust. Optimisation should be a careful refinement for a specific instrument or timeframe, not a search for a magic winning number.

Published 24 March 2026. Educational content only — not investment advice.

Educational content only — not investment advice.