Description of Hull moving average (HMA), a little-known type of moving average that almost eliminates lag in relation to price action compared to traditional moving averages.

A moving average over the price of a financial asset, such as a stock or currency pair, is a high-value trend indicator. It is possibly the most famous and widely used trading indicator of all.

Typically, the three most commonly used classic moving averages are as follows: simple, exponential, and weighted.

But today we are going to explain a little-known moving average, which is considered by many to be one of the best that exists.

It is the Hull moving average.

## What is special about the Hull moving average?

Alan Hull is an Australian mathematician and financial analyst who in 2005 decided to create a moving average that would eliminate the lag that moving averages suffer from price and make its signals more accurate.

According to Alan himself, the Hull moving average (HMA) manages to eliminate this delay almost completely and, in addition, improves the smoothing of the indicator. If this is true, we are facing a kind of Holy Grail of moving averages.

Here’s Hull moving average in action:

## How is calculated the Hull moving average?

The method for calculating the Hull moving average is basically to use weighted averages, but using the square root of the base period.

This is summarized in the following formula:

HMA = WMA(2*WMA(n/2)-WMA(n)),sqrt(n))

In this case, we put the formula for information only because it is always good to know where things come from, but currently, the Hull moving average is an indicator that appears in the main technical analysis platforms. The trader does not need to manually calculate this indicator.

Alan Hull himself, its creator, proposes in his examples a period of 16 candles, but as you already know this is an indicator that you have to adapt to your charts as you consider appropriate.

## Comparison with other moving averages

In the next series of images we will see how the Hull moving average behaves compared to the other moving averages. All are 16-period moving averages.

HMA vs SMA (simple moving average)

HMA vs EMA (exponential moving average)

HMA vs WMA (weighted moving average)

This is what the 4 moving averages look like together:

As you can see, the great advantage of the Hull moving average is that it signals trend changes before other moving averages.

## Hull moving average problems

A notable problem of Hull moving average is that it does not serve to estimate where the value is, since it moves too close to the price.

As a consequence, it is not valid for determining the price-value tension either. And you already know that this is extremely important.

I’ve tested for myself to see if, perhaps, I could use this indicator in combination with other moving averages to highlight the value zone and take advantage of it.

But the result is not good either, as you can see in the following example:

The fact that the Hull moving average does not serve to estimate where the value is located does not mean that this indicator is useless. For that we already have the classic moving averages that we have used all our lives.

Where this moving average shines is in algorithmic trading. It is ideal for automatic systems, programmers and lovers of data processing.

Here is an interesting system designed with the Hull moving average:

## Trading system based on Hull moving average

Imagine for a moment that we are stupid and blind, so we cannot see or understand what the price is doing just by looking at it (just like automatic systems).

Imagine now that we want to take advantage of this price chart to earn money, hunting some bullish movements:

As an example, and to facilitate the task, we are going to think of a system that only offers buy signals (it only opens long trades, never short trades).

The Hull moving average advantage appears when we want to detect whether the very short-term trend is bullish or bearish. This moving average does this better than virtually any other moving average.

So, we are going to buy when Hull starts to go up and sell when Hull starts to go down:

Just like any real price chart, this one also has bearish and sideways movements.

And the Hull moving average, like any other moving average, gives many false buy signals in the middle of bearishÂ  movements and, of course, in lateral phases:

To avoid these false signals as much as possible, we can add a couple of filters that, combined, will give us excellent buy signals:

First, we need to make sure that our system only gives buy signals when the trend is bullish.

Although this filtering method is not foolproof (in fact, none is), a medium term moving average will usually work very well. So we add a 50-period simple moving average.

Under normal conditions, this solves the vast majority of problems.

But we can eliminate more false signals if we implement a filter for sideway markets.

For this, we can use the ADX indicator configured in a very sensitive way.

To that ADX, which usually appears as a line in a separate window (like the stochastic oscillator), I decided to remove from view its complement (ADXR) and apply a moving average to smooth it out, and this moving average based on the ADX is what we use as an indicator. What we want with this indicator is to detect very small (short-lived) sideway markets but without showing erratic signs of sideway markets that do not exist.

The ADX is an indicator that rises when the trend (bullish or bearish) accelerates. When the trend declines, the ADX declines as well.

Therefore, to this sensitive but softened version of the ADX we add a level to determine when the market is trending or when the market is basically lateral. When the indicator falls below 45, we can consider that a small phase is taking place in which the price neither rises nor falls.

This is how we remove the stops on the rise that mislead the Hull moving average.

Therefore, to this sensitive but smoothed version of the ADX we add a level to determine when the market is trending or when the market is basically lateral. When the indicator falls below 45, we can consider that a small phase is taking place in which the price neither rises nor falls.

In this way, we can eliminate many of the false signals provided by the Hull moving average, improving its reliability.

Important note: It must be understood that the more filters are added, not only do we discard more false signals, but we also lose more good signals. This is not a problem if we trade with a large number of markets, but it must be taken into account.

A buy position is opened when the Hull moving average turns from red to green. However, we refrain from entering the market if any of the following conditions occurs:

• If the Hull moving average is below the SMA, we avoid any market entry.
• If the smoothed ADX is below 45, we avoid any market entry.
• A sell signal occurs (the buy position is closed) when the moving average Hull turns from green to red.

### System Indicator Settings

• Standard Hull moving average of 16 periods (HMA16)
• Simple moving average of 50 periods (SMA50)
• Smoothed ADX: Simple Moving Average of 6 periods (SMA 6) on the ADX (2)Â
• Threshold: ADX horizontal line at level 45

Hull moving average has its share of utility, solving a classic problem among algorithmic trading programmers, the delay of a normal moving average, which also causes the delay of their trading signals.

## Important considerations

As you have seen, Hull moving average is very interesting and you can take advantage of this technical indicator for your trading.

It is a tool worth studying. Take your tests, combine it with other indicators, change the periods, etc.

You have already seen that, despite its limitations in value estimation, it is perfect for detecting the short-term price trend, with all that this entails, shining especially in the more algorithmic approaches.

In short, try a little and see what you can get out of this moving average.

But I tell you the same thing from before and I will always repeat: This indicator, like any other, is useless if you do not take into account the structure of relevant price levels.

Hull moving average does not influence price movement. The relevant supports and resistances do.