Join waitlist
Strategies / Mean reversion / RSI Keltner Histogram Reversion

RSI Keltner Histogram Reversion

The strategy buys 1 contract when RSI(7) is below 20, the close is below the lower Keltner Channel and the histogram is positive and rising. It shorts the mirror image and exits on a price band or histogram reversal.

Mean reversionLong & shortSwingSilver1 hour
5.51Profit factor
526,556Net profit USD
45.91%Win rate
1,603Trades
-40,534Max drawdown
328Avg trade

Best run of 9. Silver, 1 hour, spread 2, from run pf:2026-10-12-SILVER-1h.tsv:5.

Entry rules, long

  1. The close is below the lower Keltner band, the 17 period EMA minus 2.7 times the 17 period ATR.
  2. The MACD is the 16 period EMA minus the 7 period EMA.
  3. The histogram, 10 times the MACD minus its 9 period average, is above zero and higher than on the previous bar.

Entry rules, short

  1. The close is above the upper Keltner band, the 17 period EMA plus 2.7 times the 17 period ATR.
  2. The histogram is below zero and lower than on the previous bar.

Exit rules

  1. A long closes when the close is below 0.99 times the entry price.
  2. A long closes when the close is above 1.015 times the entry price.
  3. A short closes when the close is above 1.01 times the entry price or below 0.985 times it.

Test conditions

PeriodUp to 2026-10-12
InstrumentSilver, 1 hour
Spread2 points
Starting capital1,000,000
CostsSpread only. Commissions and overnight financing are not included.
BarsUp to 200,000 bars, fewer where the instrument has less history
Last tested2026-10-12

Every run

Markets and timeframes tested

MarketTimeframePFTradesWin %NetMax DD
SilverBest run1 hour5.51 1,60345.91526,556 USD-40,534
Nikkei 225Dailyn/a 22850.449,333 USD-5,122
Dow JonesDailyn/a 14253.528,457 EUR-2,544
US Crude OilDailyn/a 19251.043,226 EUR-1,304
Brent Crude4 hoursn/a 27653.262,924 EUR-1,426
Nasdaq 100Dailyn/a 17039.412,676 EUR-1,477
Brent CrudeDailyn/a 9851.022,532 EUR-1,829
FTSE 100Dailyn/a 16851.791,437 EUR-862
S&P 500Dailyn/a 15938.99299 EUR-254

Charts

Results by run

Net profitMax drawdown

The code

ProBuilder code, as tested

// ==============================================================
// RSI Keltner Histogram Reversion
// ProRealAlgos Strategy Library  |  prorealalgos.com
// Type: Mean reversion
// Direction: Long & short
// Timeframe tested: 1 hour
// ==============================================================

DEFPARAM CumulateOrders = false

myRsi = RSI[7](close)
myAtr = AverageTrueRange[17](close)
kcmid = ExponentialAverage[17](close)
kcup = kcmid + 2.7 * myAtr
kclow = kcmid - 2.7 * myAtr
myMacd = ExponentialAverage[16](close) - ExponentialAverage[7](close)
sig = Average[9](myMacd)
hist = 10 * (myMacd - sig)

17 more lines: the entry and exit rules.

Setup

How to load it

  1. Copy the code with the copy button on the code block.
  2. In ProRealTime, open a chart of the instrument and timeframe you want to test, then open ProOrder > New trading system and choose "Create with programming".
  3. Paste the code, give the system a name and save it.
  4. Click "Backtest", set your own spread and position size, and run it before you consider trading it live.

Indicators used

RSIKeltner ChannelATREMASMA
Read this firstKnown weaknesses2 points
  • The code sets no stop loss, so a losing trade stays open until an exit signal arrives.
  • Results include the spread only. Commissions and overnight financing are not included.

Questions

About this strategy

Can I run RSI Keltner Histogram Reversion in ProOrder?

Yes. The code is ProBuilder and runs as an automated ProOrder system. Backtest it on your own account with your own spread and position size before trading it live.

Which markets was it tested on?

It was tested on 9 market and timeframe combinations. The best run was Silver, 1 hour, with a profit factor of 5.51 over 1,603 trades.

How large was the drawdown?

The best run had a maximum drawdown of 40,534 USD at the tested position size, against a net result of 526,556 USD.

Does it trade long, short or both?

It trades both long and short.

Related

Strategies like this one

Trend Surfer

Uses the same indicator.

1.04 PF · 10,813 trades

SMA Crossover With RSI Exit

Best run on the same market, Silver.

2.13 PF · 8,999 trades

Dip In Uptrend

Also a mean reversion strategy.

5.49 PF · 54 trades

Want strategies that are already part of a live portfolio? Join the ProRealAlgos waitlist.

The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.

Past backtest results do not guarantee future results. This is not financial advice. Curated and maintained by ProRealAlgos. ProRealTime™ is a trademark of ProRealTime SAS. prorealalgos.comStatsDocs