Empirical Mode Decomposition Trend Helix works as a trend filter indicator TradingView traders drop straight onto price. Also, the script runs a simplified two-pass sift. It builds a smooth trend line from rolling high and low envelopes, then measures how far price sits away from that line. The gap is IMF1. Signals fire when IMF1 crosses zero and the trend slope agrees, and only after the bar closes.
It is free and open source. Indeed, you can add it to any chart from the Empirical Mode Decomposition Trend Helix script page on TradingView, and the full Pine source is published there for you to read.
What Empirical Mode Decomposition Trend Helix plots on the price chart
Three lines sit on your chart. Still, the thick middle line is the trend. It turns cyan while the slope rises and purple while it falls. Thus, two faint lines flank it, each offset by half the absolute IMF1 value, so they flare wide when price runs far from trend. Circles tagged EMD mark signals below or above the bar, with two larger translucent circles behind each one for the glow. The signal bar changes colour. A soft background tint shows trend direction. Hence, a top-right dashboard reads out slope, IMF1, the trend value and position state.

How Empirical Mode Decomposition Trend Helix is built
How the sift approximates EMD
Classical empirical mode decomposition finds every local maximum and minimum, fits cubic splines through them, then averages the two splines. Next, this script approximates that step cheaply. It takes the highest value over a 10-bar window and the lowest over the same window. Then, it smooths both with a 5-bar SMA. The mean of the pair becomes the trend, m_t.
The Sift Iterations input repeats that step twice by default. Yet, note what the second pass consumes. It sifts the first mean envelope again, not the price residual a textbook sift would use. Truly, so the output is a doubly smoothed envelope midline rather than a formal intrinsic mode function. IMF1 is then simply close minus trend. Plainly, there is no spline fit, no stopping criterion, and no full decomposition into a stack of components. One component comes out.
Two stacked windows add lag. Also, the 10-bar range window delays the line, the 5-bar SMA delays it again, and running the pair twice compounds both. The trend turns late by design. Indeed, that trade buys a line that stays smooth through noise.
How a signal clears the gates
An IMF1 zero cross is the same event as close crossing the trend line. Still, the script watches both directions with ta.crossover and ta.crossunder on IMF1.
Slope decides which direction counts. Thus, the script computes trend minus trend five bars ago, divided by five. That reads the average price change per bar across the Slope Lookback. Hence, a buy needs a positive slope above Min Slope. A sell needs a negative slope past the same size. Next, min Slope ships at 0.0, so out of the box any slope pointing the right way qualifies.
Four more gates then apply. Then, position state must alternate, so two buys never print back to back. Five bars of cooldown must elapse since the last signal. Yet, the optional session filter defaults to 0000-2400, which lets every bar through until you narrow it. Finally barstate.isconfirmed must read true, so the bar must close. Truly, every plotshape reads that same gated variable, so nothing appears and vanishes mid-candle.
How to read the signals
Read the middle line first. Plainly, its colour and slope carry the whole trend view. Cyan and rising means the sifted envelope midline is climbing. Also, purple and falling means the opposite. Price crossing that line is what triggers a circle, so the line does double duty as filter and trigger.
The two faint outer lines measure stretch, not support or resistance. Indeed, they sit half an IMF1 away from the trend on each side, so they widen exactly when price has run far from the mean. Wide flares tell you the move is extended. Still, they do not spiral, despite the helix name.
Signals need a closed bar, so the circle lands at the open of the next candle. Thus, that keeps the historical chart honest, since what you see now matches what you would have seen live. It also means you act one bar after the cross, so size and stops should allow for that bar’s range.

Every Empirical Mode Decomposition Trend Helix setting explained
The script exposes 16 inputs, grouped in the settings panel exactly as shown below. Defaults are the published values.
EMD Sift
| Setting | What it does | Default | Range |
|---|---|---|---|
| Extrema Window | Rolling window for local highest/lowest. | 10 | 3 to 50 |
| Envelope Smooth | SMA length applied to envelopes. | 5 | 2 to 30 |
| Sift Iterations | Two iterations approximates one full IMF. | 2 | 1 to 4 |
| Slope Lookback | Bars used to measure trend slope. | 5 | 2 to 30 |
Signal Logic
| Setting | What it does | Default | Range |
|---|---|---|---|
| Cooldown Bars | Sets the cooldown bars used in the calculation. | 5 | 1 to 60 |
| Min Slope (price) | Slope magnitude required to qualify a signal. | 0.0 | 0.0 to 10.0 |
Filters
| Setting | What it does | Default | Range |
|---|---|---|---|
| Restrict to Session | Toggles restrict to session on the chart. | off | on / off |
| Session Window | Controls session window. | 0000-2400 |
Visual
| Setting | What it does | Default | Range |
|---|---|---|---|
| Show Trend Helix | Toggles show trend helix on the chart. | on | on / off |
| Show Dashboard | Toggles show dashboard on the chart. | on | on / off |
| Show 3-Layer Glow | Toggles show 3-layer glow on the chart. | on | on / off |
| Buy Color | Colour used for buy color. | #00ffd1 | |
| Sell Color | Colour used for sell color. | #ff3df0 | |
| Helix Color 1 | Colour used for helix color 1. | #7df9ff | |
| Helix Color 2 | Colour used for helix color 2. | #c084fc | |
| Dashboard BG | Colour used for dashboard bg. | color.new(#0a0a1f, 16) |

Alerts built into Empirical Mode Decomposition Trend Helix
The script ships 13 alert conditions. Hence, open the alert dialog on the chart, pick the indicator as the condition source, then choose the event you want. Alerts fire on the close of the bar, so they follow the same confirmed-bar rule the on-chart signals use.
- EMD Buy
- EMD Sell
- EMD Any Signal
- EMD IMF1 Up
- EMD IMF1 Down
- EMD Trend Turn Up
- EMD Trend Turn Dn
- EMD Big Excursion
- EMD Close Over
- EMD Close Under
- EMD Webhook JSON
Other markets and timeframes
Most of the calculation stays relative. Next, the windows count bars, and IMF1 is a raw price gap that scales with whatever you load. So the defaults carry over to gold, indices, crypto and equities without retuning. One input does not travel. Min Slope takes a raw price number, so 0.01 blocks nearly everything on EURUSD and passes nearly everything on an index. Then, leave it at 0.0, or set it per symbol.

Limitations worth knowing
The name promises more maths than the code delivers. Yet, this is a smoothed envelope midline plus its residual, not a spline-based decomposition. It produces one component, runs no stopping test, and never separates the further modes real EMD would extract. Truly, treat it as a robust trend line with a detrended companion series.
It filters direction and nothing else. Plainly, there is no stop logic, no target, no exit rule and no position sizing. The helix bands are cosmetic envelopes, not levels, so do not place orders on them.
Lag cuts both ways. Also, every signal is a close-versus-trend cross, and price crosses a smoothed line often inside a range. The five-bar cooldown thins those clusters but cannot remove them. Indeed, raising Extrema Window calms the line further and delays every cross with it.
Get Empirical Mode Decomposition Trend Helix on TradingView
Open Empirical Mode Decomposition Trend Helix on TradingView
If you also trade MetaTrader, the MT4 and MT5 indicator library is available below.
Get the complete indicator library
One email unlocks the full MT4 and MT5 indicator library. Still, this TradingView script stays free on TradingView – the button above adds it to your chart.
Using it alongside MetaTrader
Adding a script on TradingView takes one click, so there is no install step here. Thus, if you want the same idea on MetaTrader, the MT4 and MT5 indicator installation guide walks through copying files into the data folder and attaching them to a chart. You can also browse the full MetaTrader indicator library, the MT4 indicators section, or the other free TradingView scripts published on this profile. For related chart tools see the MT5 indicators section and the forex trading strategies guides.
External references
Frequently asked questions
Does the EMD Trend Helix repaint?
No. Hence, both the buy and sell flags include barstate.isconfirmed, and every plotshape reads those same flags. So a circle prints only after the bar closes and then stays put. Next, the script uses no request.security call, so no higher timeframe data can shift underneath it either.
Is this a real empirical mode decomposition?
It is a simplified approximation. Then, real EMD fits cubic splines through local extrema and iterates until an IMF criterion is met. This script substitutes SMA-smoothed rolling highest and lowest windows for the splines, runs a fixed number of passes, and extracts one component. The idea carries over. The exact maths does not.
What does the Sift Iterations input change?
It sets how many times the envelope step repeats. Yet, one pass gives a faster, noisier trend. Two, the default, gives a smoother line that turns later. Truly, three and four smooth further and lag more. Change it and expect the number of zero crosses to change with it.
Why did price cross the line with no circle?
Four gates can block it. Plainly, trend slope may point the wrong way or sit under Min Slope, position state may already be on that side, the five-bar cooldown may still be running, or the session filter may exclude the bar. The dashboard shows slope, IMF1 and bars since the last signal, so you can see which one applied.
How much should I rely on this indicator?
Treat it as one input, not a decision. Also, it is a chart analysis tool, not trading advice. Test it on your own markets and timeframes before relying on it. Results are not guaranteed; past performance is not indicative of future results.
