Heiken Ashi Refined MT4
- 指标
- 版本: 1.0
A two-stage smoothed Heiken Ashi indicator that filters out market noise for clearer trend reading.
What it does
Heiken Ashi Smoothed applies a two-stage moving average process on top of the classic Heiken Ashi formula. First, the raw price data is smoothed with a moving average; the Heiken Ashi candles are then built from that smoothed price. A second moving average pass smooths the resulting candles again, producing a cleaner, calmer picture of trend direction with fewer false color flips than either standard candles or plain Heiken Ashi. It is built for traders who want to read trend direction and pullbacks at a glance without being distracted by short-term noise.
Key features
- Two independent smoothing stages, each with its own moving average method and period
- Auto body width — candle thickness adjusts automatically as you zoom the chart in or out
- One-click show/hide button for the candles, with its state remembered per chart
- Custom bull/bear colors
- Works on any symbol and any timeframe, including the MetaTrader Strategy Tester
How it works
The indicator does not generate buy/sell signals by itself — it is a visual and analytical tool. Read the candle color and shape the same way you would read standard Heiken Ashi: a run of same-colored candles with little to no opposite wick suggests a clean trend; a color flip suggests momentum is turning. Because of the extra smoothing, this version reacts a little later than standard Heiken Ashi in exchange for fewer misleading flips.
Recommended setup
- Symbol: any — the indicator has no symbol-specific settings
- Timeframe: any — it recalculates for whichever timeframe it is attached to
- Account: not applicable — this is a chart indicator, not a trading system
- Multiple instances: you can attach the indicator more than once on the same chart with different settings; each instance is kept separate automatically
Input parameters
Parameters are grouped the same way they appear in the MetaTrader Inputs tab.
Smoothing
| Parameter | Default | What it does |
|---|---|---|
| Phase-1 MA method | Smoothed | The moving average method used to smooth the raw price before the first Heiken Ashi calculation. Smoothed (SMMA) gives a gentle, steady smoothing; try Exponential for a slightly faster reaction. |
| Phase-1 MA period | 6 | How many bars the first smoothing stage looks back over. Higher values produce calmer, more delayed candles; lower values react faster but show more noise. |
| Phase-2 MA method | Linear Weighted | The moving average method used for the second smoothing pass, applied to the candles produced by phase 1. |
| Phase-2 MA period | 2 | How many bars the second smoothing stage looks back over. Kept short by default so the extra smoothing does not add too much lag on top of phase 1. |
| Bars skipped at history start | 20 | Number of bars at the very start of the chart's history that are left unplotted while the smoothing "warms up". Increase this if you use long smoothing periods and see unstable candles at the far left of the chart. |
Display
| Parameter | Default | What it does |
|---|---|---|
| Auto adjust body width | On | When on, candle body thickness automatically adjusts as you zoom the chart in or out, so candles stay readable at any zoom level. Turn off to use a fixed width instead. |
| Body width | 3 | Fixed candle body thickness, used only when auto width is turned off. |
| Candle wick width | 1 | Thickness of the candle wicks (the thin upper/lower lines). This does not change with zoom. |
| Bull candle color | Dodger Blue | Color used for up (bullish) candles. |
| Bear candle color | Tomato | Color used for down (bearish) candles. |
Toggle Button
| Parameter | Default | What it does |
|---|---|---|
| Show toggle button | Off | Adds a small on-chart button that lets you show or hide the candles with one click, without removing the indicator. Left off by default so it does not clash with buttons from other indicators or Expert Advisors on a busy chart. |
| Button label | "HAS" | Text shown on the toggle button. |
| Anchor corner | Upper right | Which corner of the chart the button is positioned relative to. |
| X distance / Y distance | 70 / 60 | Button position offset, in pixels, from the chosen corner. |
| Button width / height | 70 / 20 | Size of the button in pixels. |
Requirements
- Platform: MetaTrader 4
- No external indicator files required — fully self-contained
Version 1.01 (MT5) / 1.03 (MT4) · Updated 2026-09-03 · Support via the product comments section on MQL5.
