Zero-Lag EMA Crossover Strategy: Test Faster Signals

Every moving average crossover arrives late, and a Zero-Lag EMA crossover tries to arrive sooner. That speed has a price. The same correction that removes delay also amplifies noise, so the fast signal can whipsaw more often. This long-only research example asks one question: does the earlier entry pay for the extra false starts?
The settings below are hypotheses to test. They are not measured results or a recommendation.
How Does the Zero-Lag EMA Reduce Delay?
The Zero-Lag Exponential Moving Average (ZLEMA) adjusts price before it smooths it. An ordinary exponential moving average (EMA) of 20 periods trails a steady trend by about 9.5 candles. ZLEMA estimates that delay and pushes the input forward to offset it.
The common charting recipe has three steps:
- Calculate the lag as the period minus one, divided by two, as a whole number.
- Add the difference between today’s close and the close that many candles ago to today’s close.
- Run a normal EMA on that adjusted series.
John Ehlers and Ric Way’s paper explores the same goal through an error-correcting term. Software can therefore differ, so check what your tool calculates. Our ZLEMA guide walks through the recipe with a worked example.
What Does Removing the Lag Cost?
We calculated the trade-off directly from the formulas, using a 20-period setting on artificial price series. This is a property of the maths, not a backtest.
| Test | 20-period EMA | 20-period ZLEMA |
|---|---|---|
| Delay on a steady trend | 9.5 candles | 0.5 candles |
| Share of a sudden jump absorbed in 5 candles | 39% | 79% |
| Highest overshoot after that jump | None | 19% |
| Noise left in the line, EMA = 1.00 | 1.00 | 1.84 |
The first two rows are the appeal. The last two are the risk. ZLEMA overshoots because it extrapolates recent movement, and it carries about 1.8 times the noise of an EMA.
A crossover compares two of these lines. When both are noisy, they can tangle in a sideways market. The strategy therefore needs a control, and it needs a separate view of the trend.
The Core Zero-Lag EMA Crossover Rules to Test
Use four-hour candles with a 10-period fast ZLEMA and a 30-period slow ZLEMA. Change them only after you understand the baseline.
Entry Conditions
Generate a long entry signal only when all these hold on a completed candle:
- The fast ZLEMA was at or below the slow ZLEMA on the previous candle, and is above it now.
- The close is above a 100-period EMA.
- The strategy is flat.
The first condition is the fast trigger. The second is deliberately slow, because it should not react to the noise the trigger picks up.
Model the fill at the next candle’s open, with fees and slippage included. A completed candle’s close is information, not a price you receive.
Variant A: Plain EMA Control
Replace both ZLEMAs with ordinary 10 and 30-period EMAs, and keep everything else. This is the most important test in the post. It shows what the lag correction actually adds. Compare entry dates on the same trends, then compare results after costs.
Variant B: Separation Buffer
Require the fast line to sit above the slow line by at least 0.25 times the 14-period Average True Range (ATR). ATR measures typical candle movement. A small buffer should remove crosses that are barely crosses, at the cost of a slightly later entry.
Variant C: Mixed Pair
Use a fast ZLEMA against a slow plain EMA. The slow line stays stable, while the fast line keeps its quick response. Only one line then carries the extra noise.
How Should the Position Exit?
Give the baseline two independent exits.
The signal exit fires when the fast ZLEMA crosses below the slow ZLEMA on a completed candle. Watch this one closely. ZLEMA’s overshoot can trigger it during a normal pullback inside a healthy trend.
The protective exit sits two times the 14-period ATR below entry. Capture that value when the trade opens and keep it fixed. Then size the position from your loss budget and the distance to the stop.
Record which exit closes each trade. If most winners end on a quick signal exit, test a slow ZLEMA of 50 periods for the exit only.
Where Do Zero-Lag EMA Crossover Backtests Go Wrong?
Measuring speed instead of profit. Earlier entries feel like an improvement. They only count if the results after costs improve as well. Our indicator lag post shows how to measure this on your own trades.
Skipping the control. A good ZLEMA result proves little by itself. A plain EMA version may have done the same with fewer trades. Our EMA crossover guide gives you a baseline to compare.
Ignoring turnover. Compare the trade count with the control. Then read fees paid as a share of gross profit.
Check the Calculation and the Search
Assuming one formula. Some tools round the lag differently. Others use a different correction altogether. Compare a few values with your charting tool before you trust them.
Forgetting the warm-up. The slow line and the 100-period filter need time to settle. Exclude the first part of any test window.
Testing only trending periods. Crossovers look best in clean trends. Include sideways stretches, because that is where the extra noise costs the most.
Testing many pairs, then keeping the best. Every period combination is another attempt. Log them all, and confirm the choice on data you did not use for selection.
Assembling the Zero-Lag EMA Crossover in Arrow Algo
The drag-and-drop visual builder expresses the baseline as a chain of visual blocks:
- Add the exchange’s candle data and select the four-hour timeframe.
- Connect the close to two ZLEMA blocks, and set the periods to 10 and 30.
- Feed both lines into a crossover block. Confirm the direction on a known historical candle.
- Add an EMA block with a period of 100, and compare the close with it using a condition block.
- Combine the crossover, the trend condition and a flat-position check with an AND condition block.
- Connect the result to a buy action block. Under your rules, that block sends a signal.
- Build the reverse cross and the ATR stop as separate branches into a sell action block.
Step through several signals candle by candle. Check one clean trend entry, one sideways whipsaw, and one cross the 100-period filter rejected.
Then swap the ZLEMA blocks for EMA blocks to create the control. No deployment is required for any of this. If you later choose to deploy, your rules signal your own exchange account and the exchange decides whether to execute.
Key Points to Carry Into Your Own Test
- ZLEMA cuts delay by pushing price forward before it applies an EMA.
- It carries about 1.8 times the noise of an EMA and overshoots sharp moves.
- Always run a plain EMA control on the same data and costs.
- Use a slow trend filter to separate the fast trigger from the market’s direction.
- Judge the signal on profit after costs, not on how early it fires.
Disclaimer: This content is for educational purposes only and does not constitute financial advice. Trading involves significant risk and you should only trade with capital you can afford to lose. Past performance is not indicative of future results. Always conduct your own research before making any trading decisions.
Ready to build your own automated trading strategies without writing a single line of code? Start for free at Arrow Algo and join thousands of traders who've made the switch to systematic trading.