Loading…

Gann HiLo Activator Channel

The Gann HiLo Activator computes a simple moving average of the highs and a separate simple moving average of the lows, each over the same period. Rather than comparing today's close to today's averages, it compares today's close to YESTERDAY's already-closed averages: flip up if Close[today] > SMA(High, N)[yesterday] flip down if Close[today] < SMA(Low, N)[yesterday] otherwise carry the previous trend state forward unchanged While the trend is up, the plotted line sits on the low average (acting as a rising support/stop level); while the trend is down, it sits on the high average (a falling resistance/stop level). This is what makes it a stop-and-reverse line rather than a simple average overlay - the line itself is the level a reversal must cross to flip state again, similar in spirit to a Parabolic SAR but derived from moving averages of range extremes instead of an acceleration formula. Comparing against yesterday's average rather than today's is the detail that keeps the flip decision from referencing a value that still includes the very bar being judged. Notes and limitations - Recursive: when the close sits between yesterday's high and low averages (neither flip condition triggers), the line carries the previous bar's trend state and value forward. The very first computable bar has no prior state to carry and is seeded as an up state. - Plotted with the split-buffer technique (one buffer per colour state, EMPTY_VALUE elsewhere) because this MQL4 build has no DRAW_COLOR_LINE plot type - a small visual gap can appear exactly on the bar where the state flips, since only one of the two buffers holds a value on that bar. - Needs InpPeriod + 1 bars of history before the first bar is plotted (the extra bar is for the previous-bar average lookback). - Does not repaint - each closed bar's state and value are fixed once computed.

Indicator · MT5 · v1.0 · Free

About Gann HiLo Activator Channel

Gann HiLo Activator Channel is an indicator for MetaTrader 5. It has 1 setting, such as Period. MQL source code included.

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

Settings

SettingDefaultWhat it does
Period10Averaging period for Hi/Lo

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: Moving Average · Channels & Envelopes · MT5 Indicator · MQL5 Source Code

MetaTrader 4 & 5 indicators · PolyMaria