A mean-reversion signal is often improved by a trend filter: only buy dips when price is above its 200 SMA. The idea was popularized by Connors and Alvarez (2008) with the RSI(2), very responsive because it uses only 2 bars.
Typical rule: enter if the close is above the 200 SMA and RSI(2) drops below 10; exit when the close climbs back above the 5 SMA. RSI(2) is very jumpy: it often hits 0 or 100. If no bar went down over the period, the average loss is 0 and the RSI is 100 by convention.
Each filter cuts the number of trades: 200 RSI signals × 60% above the 200 SMA = 120 trades. Fewer trades means lower fees but weaker statistics: with only 30 to 50 trades, a result may be down to luck.
Overfitting: testing 5 parameters with 4 values each gives 4⁵ = 1,024 combinations; the best one is often a fluke. Pros fix the rules in advance, keep an out-of-sample period and distrust an equity curve that looks too good.
Examples
COMBO-X (fictional market) : Price stays above its long-term average (gold curve): the trend is up. A three-bar pullback drops RSI(2) toward 5; the rule buys at the close, then sells when price climbs back above its 5 SMA, often a few bars later.
2008: Connors, Alvarez and the RSI(2) : In Short Term Trading Strategies That Work (2008), Larry Connors and Cesar Alvarez describe rules for buying short pullbacks in indices, filtered by the 200 SMA, including the RSI(2). Lesson: a published rule is known to everyone; McLean and Pontiff (2016) show that published anomalies earn less on average after publication. So retest with recent data and realistic fees.
Key terms
Trend filter
Condition that only allows buys in an underlying uptrend
RSI(2)
RSI computed over 2 bars, very responsive, often hitting extremes
Overfitting
Rules tuned too closely to history that fail on new data
Out of sample
Period not used to tune the strategy, kept for the final test