Dynamic Momentum Index
A fixed-period RSI has a fixed reaction speed regardless of what the market is doing. That is a compromise: the period that responds well during a volatile stretch is too twitchy during a calm one, and the period that stays smooth during a calm stretch lags badly the moment volatility jumps. Chande and Kroll's Dynamic Momentum Index (published in "The New Technical Trader", 1994) removes that compromise by making the RSI period itself a function of volatility. It compares a short (5-bar, configurable) standard deviation of closing price to that same short standard deviation's own 10-bar (configurable) average - a ratio above 1 means short-term volatility is currently running hotter than its recent norm, below 1 means it is unusually calm. The base RSI period (14 by default) is divided by that ratio: elevated volatility shortens the period so the oscillator reacts faster exactly when the market is moving fastest, and unusually calm volatility lengthens the period so the oscillator does not whipsaw on quiet noise. The result is clamped between InpMinPeriod and InpMaxPeriod so it can never collapse toward zero or run away to an impractically long window. Because the effective period changes every bar, this indicator computes each bar's RSI as a direct windowed average of up/down moves (the "Cutler" RSI variant) rather than Wilder's usual recursive smoothing - a recursive smoother has no clean way to carry its internal state across a period that keeps changing size, while a plain windowed average simply recomputes cleanly over whatever period that bar calls for. Notes and limitations - Needs roughly InpMaxPeriod + InpVolAvgWindow + InpVolWindow bars of history before it plots anything; on a freshly opened chart with thin history it stays blank until enough bars are available. - The dynamic period is recomputed independently on every bar rather than smoothed itself, so it can change noticeably from one bar to the next during a volatility regime shift - this is the indicator working as designed, not noise to be filtered out. - Because the RSI leg uses a simple windowed average rather than Wilder's recursive smoothing, readings will not exactly match a standard MT4 RSI even when InpMinPeriod and InpMaxPeriod are both forced to the same fixed value - the smoothing method itself differs, not just the period.
Indicator · MT5 · v1.0 · Free
About Dynamic Momentum Index
Dynamic Momentum Index is an indicator for MetaTrader 5. It can alert you with a pop-up, sound, email or push message. It has 6 settings, such as Base period, Vol window and Vol avg window. MQL source code included.
Files in the download: DynamicMomentumIndex.ex5, DynamicMomentumIndex.mq5, DynamicMomentumIndex.txt.
Settings
| Setting | Default | What it does |
|---|---|---|
| Base period | 14 | Base RSI period divided by the volatility ratio to get the dynamic period |
| Vol window | 5 | Bars in the short standard-deviation window (Chande's original: 5) |
| Vol avg window | 10 | Bars the short standard deviation is itself averaged over (Chande's original: 10) |
| Min period | 5 | Floor on the dynamic RSI period |
| Max period | 30 | Ceiling on the dynamic RSI period |
| Alerts | true | Alert once per closed bar crossing 30 or 70 |
How to install
- Download the ZIP from your PolyMaria library and unzip it.
- In MetaTrader 5 open File → Open Data Folder, then go to MQL5 → Indicators.
- Copy the .mq5 file(s) there. Put any .mqh files in MQL5 → Include.
- Open the .mq5 file in MetaEditor and press Compile (F7) if MetaTrader does not show it.
- Drag the indicator from the Navigator onto a chart and adjust the settings.
Tags: RSI · Momentum · Alerts · MT5 Indicator · MQL5 Source Code