Loading…

Absorption Bar Detector

Absorption happens when a large amount of trading activity fails to move price much, because a resting order (or a determined opposing side) is soaking up everything thrown at it. On a chart that shows up as a bar with far more ticks than its neighbours but a range no bigger than usual, often right before a reversal. The trouble is that "far more ticks" and "no bigger range" both require a baseline, and eyeballing that baseline bar to bar is unreliable. This indicator computes both baselines explicitly: average tick volume over a trailing lookback window, and a simple true-range ATR over the same window, with the tested bar itself excluded from both averages so a single extreme bar cannot inflate its own threshold. A bar only qualifies when tick volume is at least InpVolumeMultiplier times the average AND its range is at most InpRangeFraction of ATR. Direction is read from where the close settled inside the bar's own range - close near the high marks bullish absorption (selling pressure absorbed), close near the low marks bearish absorption. A close sitting in the middle third is deliberately left unmarked, since heavy volume with no resolved direction is not an actionable read. Tick count is MQL4's only volume proxy on most retail feeds - it counts price changes, not confirmed traded size - so this identifies activity bursts, not verified institutional footprints. Notes and limitations - Both baselines exclude the tested bar, but they are still simple trailing averages - a market that has just gone through a genuine volatility regime shift will produce a run of flags until the baseline catches up. - Tick volume is an activity proxy, not confirmed traded size or real exchange volume; brokers with thin or synthetic tick feeds will produce noisier baselines than a deep ECN feed. - Bar 0 (the still-forming bar) is never signalled, since its volume and range are still growing bar by bar. - This flags a pattern, not a trade signal. It does not size a position, place a stop, or account for spread and slippage.

Indicator · MT4 · v1.0 · Free

About Absorption Bar Detector

Absorption Bar Detector is an indicator for MetaTrader 4. It draws buy and sell arrows on the chart and can alert you with a pop-up, sound, email or push message. It has 6 settings, such as Volume lookback, Volume multiplier and Atr period. MQL source code included.

Files in the download: AbsorptionBarDetector.ex4, AbsorptionBarDetector.mq4, AbsorptionBarDetector.txt.

Settings

SettingDefaultWhat it does
Volume lookback20Bars used to average tick volume
Volume multiplier2.0Bar volume must be at least this many times the average
Atr period14ATR period used as the range baseline
Range fraction0.5Bar range must be at most this fraction of ATR
Close third ratio0.33Close must sit within this fraction of the bar's extreme to set direction
AlertstrueAlert once per closed bar on a new absorption flag

How to install

  1. Download the ZIP from your PolyMaria library and unzip it.
  2. In MetaTrader 4 open File → Open Data Folder, then go to MQL4 → Indicators.
  3. Copy the .mq4 file(s) there. Put any .mqh files in MQL4 → Include.
  4. Open the .mq4 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: ATR · Volume · Buy/Sell Arrows · Alerts · MT4 Indicator · MQL4 Source Code

MetaTrader 4 & 5 indicators · PolyMaria