STD-Filtered, Adaptive Exponential Hull Moving Average
Sep 13, 2022

The STD-Filtered, Adaptive Exponential Hull Moving Average indicator provides a low-lag, smoothed trend-following signal by combining an adaptive exponential version of the Hull Moving Average with Kaufman Efficiency Ratio logic and standard deviation filtering.
Usage
The Usage section describes how the script can be used to identify market trends and potential entry points with reduced noise. Traders can use the indicator to determine market direction based on the color-coded moving average line and integrated trade signals.
- Trend Identification: The indicator colors the average line and chart bars based on the current trend state (bullish or bearish).
- Adaptive Smoothing: The script adjusts its responsiveness based on market efficiency. In trending markets, it becomes more responsive, while in choppy markets, it increases smoothing to avoid false signals.
- Volatility Filtering: By applying standard deviation "stepping," the indicator can flatline during periods of low volatility or minor price fluctuations, helping traders avoid "whipsaw" price action.
- Signal Execution: Visual labels ("L" for Long and "S" for Short) appear when the trend direction shifts, providing clear entry or exit indications.
Details
The script evolves the traditional Hull Moving Average (HMA) by replacing the Weighted Moving Average (WMA) components with Exponential Moving Averages (EMA), creating an Adaptive Exponential Hull Moving Average (AEHMA).
To determine the level of adaptivity, the script calculates Kaufman’s Efficiency Ratio (ER). The ER measures the "signal-to-noise" ratio by dividing the total price change over a period by the sum of absolute price movements. A higher ER (closer to 1) indicates a strong, efficient trend, while a lower ER (closer to 0) indicates noise or congestion.
Furthermore, a standard deviation filter is implemented to create "steps." This filter compares the change in value to a multiple of the standard deviation; if the change is smaller than the threshold, the value remains unchanged. This helps in filtering out insignificant price movements that do not represent a true change in trend.
Settings
Source Settings
- Heiken-Ashi Better Smoothing: Selects the smoothing algorithm (AMA, T3, or Kaufman) for specific source types.
- Source: Provides a wide array of price source options, including standard price points, Heikin-Ashi candles, and Loxx's expanded source types.
Basic Settings
- Signal-to-Noise Ratio (SNR) Period: The lookback period used to calculate market efficiency.
- Fast Period: The period for the fast EMA component of the AEHMA.
- Slow Period: The period for the slow EMA component of the AEHMA.
- Gain: A multiplier that affects the sensitivity of the adaptive logic.
- Beta: A coefficient used in the calculation of the SNR.
Filter Settings
- Filter Options: Determines whether the standard deviation filter is applied to the Price, the AEHMA, both, or none.
- Filter Deviations: The number of standard deviations used as the threshold for the filtering "steps."
- Filter Period: The lookback period used for calculating the standard deviation.
UI Options
- Color bars?: Toggles whether the chart bars are colored based on the indicator trend.
- Show signals?: Toggles the visibility of Long and Short labels on the chart.
Moving Average Inputs
- Fast/Slow End (KAMA/AMA): Specific parameters used only when Kaufman or Adaptive Moving Average smoothing is selected in the Source Settings.
FAQ
How do I interpret the colors of the indicator? A green line and bars typically indicate a bullish trend where the AEHMA is rising, while a red line and bars indicate a bearish trend where the AEHMA is falling.
What does the "Gain" setting do? The Gain setting adjusts how aggressively the indicator responds to changes in market efficiency; higher values generally lead to more pronounced adaptive behavior.
How can I access this indicator? You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.
Free indicator
Get free access to this indicator on the platforms below.
Unlock the entire LuxAlgo Library
Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.