Best Higher High Lower Low Indicator: Swing Structure Map

Written by Dominic Walsh · Published · Last updated

The best higher high lower low indicator maps swing structure and tags every pivot. Confirmed fractal highs and lows become HH, HL, LH or LL labels. A zigzag section chains them together. A fresh Higher High or Lower Low then prints a break of structure signal.

This build ships as best-higher-high-lower-low-indicator-indicator-forexmt4systems.ex4 for MT4 and best-higher-high-lower-low-indicator-indicator-forexmt4systems.ex5 for MT5; the screenshots below come from EURUSD H1.

Platforms MT4 (.ex4) + MT5 (.ex5)
Chart window Main price chart
Plots 3: Structure ZigZag, BOS Buy, BOS Sell
Alerts popup, push notification, email, sound
Inputs 15

What the Best Higher High Lower Low Indicator draws on the chart

Structure ZigZag chains the pivots. It runs a slate gray section line from each confirmed swing high to the next confirmed swing low. The shape of the market reads in one look.

Two arrow plots handle the signals. BOS Buy places a lime arrow under a swing that beat the previous high. BOS Sell places a red one above a swing that broke the previous low. Text labels sit beside each pivot and spell out HH, HL, LH or LL.

A small panel in the chart corner reports the last high tag, the last low tag and the resulting bias. Bias reads bullish on HH with HL, bearish on LH with LL, and range for any other mix.

  • Structure ZigZag: section, slate gray, width 1
  • BOS Buy: arrow, lime, width 3, arrow code 233
  • BOS Sell: arrow, red, width 3, arrow code 234
The best higher high lower low indicator tagging HH and LL swings with a BOS Buy arrow on EURUSD H1.
The best higher high lower low indicator tagging HH and LL swings with a BOS Buy arrow on EURUSD H1.

How the Best Higher High Lower Low Indicator calculates its values

Confirming a swing

InpDepth defaults to 5. It sets how many bars each side must stay inside the pivot. A high qualifies only when the bars after it and the bars before it all sit lower. Because the right-hand bars have to exist first, every pivot lands several bars back from the live edge.

Classifying the pivot

Each new swing high looks back for the previous one. InpMaxGap defaults to 1000 and caps that search in bars. A higher reading earns the HH tag and a lower one earns LH. Swing lows earn HL or LL the same way. Dow Theory readers will recognise the four labels at once.

Breaking structure

A fresh HH fires the buy side. The code writes the swing low minus the offset into BOS Buy and drops a BUY text label under it. A fresh LL does the mirror on BOS Sell. Tags without a break, such as LH or HL, print on the chart and raise no signal.

How to read the signals

Read the tag sequence, not single markers. HH followed by HL describes an uptrend that keeps making progress, and the panel says bullish while that holds.

A BOS Buy after a run of LH and LL marks the first crack in a downtrend. Traders who follow structure often wait for a higher low to form after that break before they act.

Everything confirms several bars late. Treat the newest tag as provisional context rather than a live trigger, since the pivot beside it only became valid once those bars closed.

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

EnableAlerts and EnablePopup start switched on, while EnablePushNotify, EnableEmail and EnableSound start off and SoundFile points at alert.wav. The check runs on the newest confirmable pivot once per bar, so a break sends one message.

Every Best Higher High Lower Low Indicator input

Core settings

Setting What it does Default
InpDepth Fractal depth N (bars each side). Bars needed on each side of a pivot; 8 or more smooths a noisy chart. 5
InpMaxGap Max bars back to find previous swing. How far back the search looks for the previous swing of the same type, in bars. 1000

Display settings

Setting What it does Default
InpArrowOffset Arrow offset (points). Distance in points between the marker and the swing candle. 50
InpShowTags Show HH/HL/LH/LL tags. Turns the HH, HL, LH and LL text on or off without removing the zigzag. on
InpFontSize Tag font size. 9
InpFont Tag font. Arial Black
ShowPanel Show structure panel. Shows or hides the corner readout of the last two tags and the bias. on
PanelCorner Corner (0=UL,1=UR,2=LL,3=LR). Chart corner for that readout, from top left through to bottom right. 0
PanelBg (see inputs panel) black

Alert settings

Setting What it does Default
EnableAlerts (see inputs panel) on
EnablePopup (see inputs panel) on
EnablePushNotify (see inputs panel) off
EnableEmail (see inputs panel) off
EnableSound (see inputs panel) off
SoundFile (see inputs panel) alert.wav
best higher high lower low indicator: Inputs panel with InpDepth, InpMaxGap and the ShowPanel switch.
Inputs panel with InpDepth, InpMaxGap and the ShowPanel switch.

Settings that fit your chart

Structure reading suits any liquid market. The screenshot uses EURUSD H1, where the shipped depth spaces pivots out well across a session. Majors, gold and index CFDs all behave sensibly on H1 and H4. On M1 and M5 the same depth turns micro-wiggles into pivots, so lift it before you read anything into the tags.

When the Best Higher High Lower Low Indicator fails

Confirmation lag is the price of stability. Nothing prints until the bars to the right of a pivot have closed, so the marker appears well after the actual high or low.

Choppy ranges produce contradictory tags. A market that grinds sideways can print HH and LL within a few bars of each other, and the panel then flips to range without telling you much.

Break of structure signals fire on every new extreme. In a strong trend that means a long series of BOS Buy marks, most of which confirm what the chart already showed.

The lookback stops after the search limit runs out. On a chart with a long stretch between comparable swings, the tool treats the new pivot as the first of its kind and skips the tag.

Copy best-higher-high-lower-low-indicator-indicator-forexmt4systems.ex4 into MQL4/Indicators and best-higher-high-lower-low-indicator-indicator-forexmt4systems.ex5 into MQL5/Indicators, then restart the terminal and drag the Best Higher High Lower Low Indicator onto a chart. The step-by-step guide with screenshots is at how to install MT4 and MT5 indicators.

Download the Best Higher High Lower Low Indicator for MT4 and MT5

The zip best-higher-high-lower-low-indicator-indicator-forexmt4systems.zip holds best-higher-high-lower-low-indicator-indicator-forexmt4systems.ex4, best-higher-high-lower-low-indicator-indicator-forexmt4systems.ex5 and a short README, compiled files only. 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

How does InpDepth change the pivots the zigzag uses?

It sets how many bars each side of a candle must stay inside it before that candle counts as a swing. The shipped value gives a readable structure on H1. Raise it and you get fewer, larger swings with more lag. Lower it and small wiggles start earning tags.

What separates a HH tag from a BOS Buy signal?

The tag classifies a pivot; the signal marks the moment structure breaks. Every confirmed swing high earns either HH or LH, and only the HH case writes into BOS Buy and drops a BUY label. So the chart carries far more tags than signals at any time.

Does ShowPanel affect the tags or only the display?

Only the display. ShowPanel draws the corner readout with the last high tag, the last low tag and the bias word, and switching it off removes those objects. Pivot detection, the zigzag and both signal buffers carry on exactly as before.

Can I trust a tag on the newest bars of a EURUSD H1 chart?

Not yet. A pivot needs several bars to its right before the code confirms it, so the last few candles carry no tags at all. What you see near the right edge stays provisional until those bars close. Read the older, settled part of the structure for context.

Are results guaranteed?

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

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