Market Structure Low High Indicator: Four Swing Labels

Written by Dominic Walsh · Published · Last updated

The market structure low high indicator does the labelling you would otherwise do by hand. Every confirmed swing gets compared against the previous one inside `StructureLookback` bars, then tagged as a higher high, lower high, higher low or lower low. Four colours, four meanings.

This build ships as a compiled .ex4 for MT4 and .ex5 for MT5; the screenshots below come from EURUSD H1.

Platforms MT4 (.ex4) + MT5 (.ex5)
Chart window Main price chart
Plots 4: HH, LH, HL, LL
Alerts popup, push notification, email, sound
Inputs 13

What the Market Structure Low High Indicator draws on the chart

HH is the lime mark above a swing that beat the previous high.

LH is the tomato mark above one that did not.

HL is the deep sky blue mark below a swing low that held above the last one.

LL is the orange mark below one that broke it.

  • HH: arrow, lime, width 2, arrow code 233
  • LH: arrow, tomato, width 2, arrow code 234
  • HL: arrow, deep sky blue, width 2, arrow code 233
  • LL: arrow, orange, width 2, arrow code 234
Market structure low high indicator on EURUSD H1 with HH, LH, HL and LL tags
Market structure low high indicator on EURUSD H1 with HH, LH, HL and LL tags

How the Market Structure Low High Indicator calculates its values

Confirming a swing

IsSwingHigh and IsSwingLow test the bar at index plus `FractalLeftRight` `3`. The bar must beat every neighbour within three positions on both sides. Those three right-hand bars are the confirmation delay.

Finding the comparison

The code walks back up to `StructureLookback` `50` bars for the previous swing of the same kind. prevHigh holds that price. A current high above it earns the HH label, and one below earns LH.

The extras

`ShowOrderBlocks` highlights the last reaction zone with a rectangle, built from the swing bar high and its open. `ShowLiquidity` marks equal highs and lows. Both draw objects rather than buffers.

How to read the signals

A run of HH and HL tags is the textbook uptrend structure.

The first LH after a run of HH is the classic warning sign.

Every tag arrives three bars after the swing it describes.

Widen `StructureLookback` to compare against older swings.

Alert channels in this build: popup, push notification, email and sound, one message per closed bar.

`EnableAlerts` starts on with `EnablePopup` and `EnableSound` both true, while `EnablePushNotify` and `EnableEmail` begin false. `SoundFile` picks the clip. Swings confirm on closed bars, and the guard allows one label message per bar.

Every Market Structure Low High Indicator input

Core settings

Setting What it does Default
StructureLookback Pivot detection window. Bars searched for the previous swing, default `50`. 50
FractalLeftRight Bars left/right for swing confirmation. Bars each side confirming a swing, default `3`. 3

Display settings

Setting What it does Default
ShowOrderBlocks Highlight last reaction zone. Highlights the last reaction zone, default `true`. on
ShowLiquidity Mark equal highs / lows. Marks equal highs and lows, default `true`. on
BullColor Bullish colour, default lime. lime
BearColor Bearish colour, default tomato. tomato
ArrowOffsetPoints Distance of arrows from bar. Tag distance from the bar in points, default `15`. 15

Alert settings

Setting What it does Default
EnableAlerts Master switch for the structure label alerts, default `true`. on
EnablePopup Terminal dialog on a new label, default `true`. on
EnablePushNotify Phone push on a new label, default `false`. off
EnableEmail Mail delivery on a new label, default `false`. off
EnableSound Sound playback on a new label, default `true`. on
SoundFile Wav clip for the structure alert, default `alert.wav`. alert.wav
Market structure low high indicator inputs: StructureLookback, FractalLeftRight, ShowOrderBlocks
Market structure low high indicator inputs: StructureLookback, FractalLeftRight, ShowOrderBlocks

Settings that fit your chart

Structure labelling needs swings large enough to read. EURUSD H1 is the reference chart, where `FractalLeftRight` at `3` picks turns lasting a few hours. On M5 the tags come thick and the picture gets muddled. On H4 each tag describes a swing worth trading around.

When the Market Structure Low High Indicator fails

A three-bar swing is small, so many tags describe noise rather than structure.

The comparison uses one previous swing, which ignores everything before it.

`ShowOrderBlocks` marks the last reaction zone only, and never tracks a return to it.

Copy the compiled Market Structure Low High Indicator file into your MQL4/Indicators folder, and the MT5 build into MQL5/Indicators, then restart the terminal and drag it onto a chart. The step-by-step guide with screenshots is at how to install MT4 and MT5 indicators.

Download the Market Structure Low High Indicator for MT4 and MT5

The zip holds the compiled Market Structure Low High Indicator build for MT4 and MT5, plus a short README. Compiled files only, no source. Enter your email below and the download link arrives in your inbox.

Download this indicator free

Enter your email and the file is yours. You also get the full MT4 and MT5 library.

  • 1,380+ indicators
  • MT4 and MT5 files
  • No spam, unsubscribe any time

FAQ

What separates an HH tag from an LH tag?

Only the comparison. Both sit above a confirmed swing high. HH means that high beat the previous one inside `StructureLookback` `50` bars. LH means it fell short. The same logic runs upside down for HL and LL.

How far back does StructureLookback compare?

Up to fifty bars, hunting for the previous swing of the same kind. On EURUSD H1 that is two days. Widen it to compare against older structure, which produces fewer HH tags and more LH ones during a slow grind.

What does ShowOrderBlocks draw?

A rectangle over the last reaction zone, built from the swing bar high and its open. It marks the area price left from. The tool draws it and stops, so nothing tracks whether price comes back.

Why does FractalLeftRight delay every tag?

Because a swing cannot be confirmed until three newer bars have closed without beating it. On H1 that is three hours. The delay is unavoidable in any fractal method and applies equally to all four labels.

Are results guaranteed?

No. Trading involves risk. Results are not guaranteed; past performance is not indicative of future results. Use the Market Structure Low High Indicator as one input. Always backtest before trading live.

Category: this is part of our Smart Money collection. Browse more Smart Money for MetaTrader, or explore every MT4 indicator and MT5 indicator on the site.

External references

Dominic Walsh - Forex trader and MT4/MT5 developer

About the author

Written by Dominic Walsh, a Forex trader and MT4/MT5 indicator, Expert Advisor and script developer. Every tool on forexmt4systems.com is tested on live charts before release and ships with ready-to-use compiled MT4 (.ex4) and MT5 (.ex5) files. Learn more about the trader and developer behind this site.

How we build, test and correct every tool: Editorial & Testing Policy. Trading carries risk; see the disclaimer.

Leave a Comment