indicator · on price · open source

Ehlers Hilbert Trendline

Deepwick · @deepwickv1Updated 2 Oct 2026▲ 0 users
Running…
Loading chart…

About

Ehlers Hilbert Trendline — a simple weighted moving sum that approximates the in-phase component of the Hilbert transform. Smoother than a 4-bar SMA, with no lag amplification.

  • Overlay the trigger (just the 2-bar projection of price) for entry signals.
  • Cheaper to compute than the full Hilbert engine.

Source code

//@version=5
indicator("Ehlers Hilbert Trendline", overlay=true)
src = (high + low) / 2
ht = (4 * src + 3 * src[1] + 2 * src[2] + src[3]) / 10
p_Hilbert_Trendline = plot(ht, "Hilbert Trendline", color=color.blue, linewidth=2)
alertcondition(ta.crossover(close, ht), "Above HT", "Close crossed above the Hilbert trendline")
alertcondition(ta.crossunder(close, ht), "Below HT", "Close crossed below the Hilbert trendline")

Comments

No comments yet.

Sign in to comment.