Moving Averages

Kyle Niedzwiecki

Easy Loot Moving Averages Example on Bitcoin

August 6, 2021

What are Moving Averages?

The moving average (MA) is a simple technical analysis indicator that smooths out previous price data by creating a constantly updated average price. The average is taken over a specific trading period, depending on whatever time period the trader chooses. It is called a “moving” average because it is continually recalculated based on the latest price data according to the MA’s time frame. Moving average strategies are popular and can be tailored to any time frame, suiting both long-term investors and short-term traders.

Moving averages are generally calculated to identify the trend direction of an asset to determine its support and resistance levels. Moving averages are a trend-following, otherwise known as lagging, indicator because it is based off of historical price data. The longer the time period for the moving average, the greater the lag. So in saying this, a 200-day moving average will have a much greater degree of lag than a 20-day moving average because it contains all of the historical price data for the entire past 200 days. 

Moving averages are a totally customizable indicator, which means that an investor can freely choose whatever time frame best suits them when calculating an average. There is no right or wrong answer, so picking the ‘correct’ moving average is like art in a way. The most common time periods used in moving averages and the industry standard are the: 8, 30, 50, 100, and 200 time periods. Technical analysts and investors may choose different time periods of varying lengths to calculate moving averages based on their trading objectives. The best way to figure out which moving average works best for you is to experiment with a number of different time periods until you find one that fits your strategy.

A rising moving average indicates that the asset is in an uptrend, while a declining moving average indicates that the asset is in a downtrend. Upward momentum is confirmed with a bullish crossover, which occurs when a shorter-term moving average crosses above a longer-term moving average. On the other hand, downward momentum is confirmed with a bearish crossover, which occurs when a short-term moving average crosses below a longer-term moving average.

Example of Moving Averages

Looking at the 2D time frame of BTC (Bitcoin) we can see that there are three different moving average lines; the red represents the 30MA, green is the 100MA, and the black line is the 200MA. This is the ‘Golden Cross’ Indicator that uses all 3 of these averages and dots a yellow circle when a cross occurs. This chart represents a general upwards trend, shown by the three averages in an upwards swing right behind the price.

How to Trade Moving Averages

Traders trade moving averages as dynamic support & resistance lines, with the more advanced trading using the “Golden Cross” & “Death Cross” terms coined with the use of multiple moving averages. The definition of the Golden Cross is when the 50MA crosses above the 200MA indicating bullish momentum, while the Death Cross is when the 50MA crosses below the 200MA. Both crosses indicate that there has been a spark of interest in the market.

How to Calculate Simple Moving Averages

A simple moving average is formed by computing the average price of a security over a specific number of periods. Most moving averages are based on closing prices; for example, a 5-day simple moving average is the five-day sum of closing prices divided by five. As its name implies, a moving average is an average that moves. Old data is dropped as new data becomes available, causing the average to move along the time scale. The example below shows a 5-day moving average evolving over three days.

Daily Closing Prices: 11,12,13,14,15,16,17

First day of 5-day SMA: (11 + 12 + 13 + 14 + 15) / 5 = 13

Second day of 5-day SMA: (12 + 13 + 14 + 15 + 16) / 5 = 14

Third day of 5-day SMA: (13 + 14 + 15 + 16 + 17) / 5 = 15

The first day of the moving average simply covers the last five days. The second day of the moving average drops the first data point (11) and adds the new data point (16). The third day of the moving average continues by dropping the first data point (12) and adding the new data point (17). In the example above, prices gradually increase from 11 to 17 over a total of seven days. Notice that the moving average also rises from 13 to 15 over a three-day calculation period. Also, notice that each moving average value is just below the last price. For example, the moving average for day one equals 13 and the last price is 15. Prices the prior four days were lower and this causes the moving average to lag.

How to Calculate Exponential Moving Averages

Exponential moving averages (EMAs) reduce the lag by applying more weight to recent prices. The weighting applied to the most recent price depends on the number of periods in the moving average. EMAs differ from simple moving averages in that a given day’s EMA calculation depends on the EMA calculations for all the days prior to that day. You need far more than 10 days of data to calculate a reasonably accurate 10-day EMA.

There are three steps to calculating an exponential moving average (EMA). First, calculate the simple moving average for the initial EMA value. An exponential moving average (EMA) has to start somewhere, so a simple moving average is used as the previous period’s EMA in the first calculation. Second, calculate the weighting multiplier. Third, calculate the exponential moving average for each day between the initial EMA value and today, using the price, the multiplier, and the previous period’s EMA value. The formula below is for a 10-day EMA.

Initial SMA: 10-period sum / 10 

Multiplier: (2 / (Time periods + 1) ) = (2 / (10 + 1) ) = 0.1818 (18.18%)

EMA: {Close – EMA(previous day)} x multiplier + EMA(previous day). 

Simple vs. Exponential Moving Averages

Even though there are clear differences between simple moving averages and exponential moving averages, one is not necessarily better than the other. Exponential moving averages have less lag and are therefore more sensitive to recent prices – and recent price changes. Exponential moving averages will turn before simple moving averages. Simple moving averages, on the other hand, represent a true average of prices for the entire time period. As such, simple moving averages may be better suited to identify support or resistance levels.

Moving average preference depends on objectives, analytical style, and time horizon. Chartists should experiment with both types of moving averages as well as different timeframes to find the best fit. The chart below shows IBM with the 50-day SMA in red and the 50-day EMA in green. Both peaked in late January, but the decline in the EMA was sharper than the decline in the SMA. The EMA turned up in mid-February, but the SMA continued lower until the end of March. Notice that the SMA turned up over a month after the EMA.

Related Posts

Leave a Comment

0 Comments

Submit a Comment

Your email address will not be published.