Loading…

Body Momentum Ribbon

Momentum tools usually smooth an oscillator; this one reads it straight off the candles. A "streak" is a run of consecutive bars where each body is both the same direction as, and strictly larger than, the immediately prior body - genuine accelerating momentum, not just "several bullish bars in a row" (which includes plenty of stalling, shrinking-body runs that aren't accelerating at all). The streak resets to 1 the moment a bar breaks direction or fails to expand on the prior body, so the ribbon only stays "strong" while expansion is actually continuing. Native MQL4 has no DRAW_COLOR_LINE (that family is MQL5-only), so per-bar colour is built with the standard split-buffer trick used elsewhere in this catalogue: four buffers - strong bullish, weak bullish, strong bearish, weak bearish - each holding EMPTY_VALUE everywhere except the bars in that exact state, all anchored at the same price offset below the Low so together they read as one continuous multi-colour ribbon rather than four separate lines. The offset itself is sized from ATR rather than a fixed point value, so the ribbon sits a sensible distance below price on both a tight-spread major and a wide-range instrument like gold or an index CFD without needing per-symbol tuning. Notes and limitations A doji-like bar (Close == Open exactly) has no direction and breaks any streak in progress rather than continuing or reversing it - documented behaviour, not an edge case bug. The streak comparison looks only at the immediately prior bar's body, so a strong-looking multi-bar move that alternates slightly larger and slightly smaller bodies bar-to-bar will not read as one continuous streak even though the overall move is genuinely strong; that is a real limitation of a purely bar-to-bar expansion test versus a smoothed momentum measure. This is a visual momentum read only - it does not predict continuation or reversal and does not manage a trade.

Indicator · MT5 · v1.0 · Free

About Body Momentum Ribbon

Body Momentum Ribbon is an indicator for MetaTrader 5 based on ATR. It has 3 settings, such as Strong streak, Atr period and Offset atr mult. MQL source code included.

Files in the download: BodyMomentumRibbon.ex5, BodyMomentumRibbon.mq5, BodyMomentumRibbon.txt.

Settings

SettingDefaultWhat it does
Strong streak3Consecutive expanding bars needed to count as "strong"
Atr period14ATR period used to size the ribbon's offset below price
Offset atr mult0.5Ribbon offset below Low, as a multiple of ATR

How to install

  1. Download the ZIP from your PolyMaria library and unzip it.
  2. In MetaTrader 5 open File → Open Data Folder, then go to MQL5 → Indicators.
  3. Copy the .mq5 file(s) there. Put any .mqh files in MQL5 → Include.
  4. Open the .mq5 file in MetaEditor and press Compile (F7) if MetaTrader does not show it.
  5. Drag the indicator from the Navigator onto a chart and adjust the settings.

Download the PDF guide

Tags: Momentum · Oscillator · ATR · MT5 Indicator · MQL5 Source Code

MetaTrader 4 & 5 indicators · PolyMaria