How it is calculated
HA close = (open plus high plus low plus close) divided by 4. HA open = (previous HA open plus previous HA close) divided by 2, on the first bar (open plus close) divided by 2. HA high is the highest and HA low the lowest of the bar's extreme, HA open and HA close. direction is +1 when HA close is above HA open, -1 below, 0 equal; run counts the candles in a row of one direction.
Reference: Valcu 2004, Technical Analysis of Stocks and Commodities
How to read it
A run of rising candles without a lower wick is a strong up move, a small candle with wicks on both sides a pause. The values are averages, not prices that traded: an order fills at the real price, never at HA close. The first bar's seed fades by half with every bar, below 0.1 percent after ten.
In a strategy
Following the colour: with ha = ctx.ind("heikin_ashi") go long when ha.direction turns +1 with ha.no_opposite_wick at 1, and exit once ha.direction turns -1, or wait for ha.run of 3.
Inputs
It takes no inputs.
What it draws
| Line | Drawn as |
|---|---|
| HA close | Line |
| HA open | Line |
Used in
No strategy template reads it yet.