Moving averages smooth out price data to form an indicator that tracks trends. They do not predict the direction of the price, but rather determine the current direction, although they lag behind due to the fact that they are based on past prices. Regardless, mobile environments help regulate price action and filter noise. They also form the core blocks of many other technical indicators and overlap with each other, such as the Bollinger Bands, the MACD Oscillator. The two most popular types of moving averages are Simple Moving Average (SMA) and Exponential Moving Average (EMA).
Nifty chart with both an SMA 20 and an EMA 50
Simple Moving Average
A simple moving average is formed by calculating the average price of a security over several periods. Most moving averages are based on closing prices; for example, a simple 5-day moving average is the five-day sum of closing prices divided by five. As the name suggests, a moving average is a moving average. Old data is deleted as new data becomes available, causing the media to move up in the timeline. The example below shows a 5-day moving average that changes 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
Moving Average Double Crossovers
The two moving averages can be used together to generate crossovers. In Technical Analysis of Financial Markets, John Murphy calls it the “double crossing method”. Double crossings include a relatively short moving average and a relatively long moving average. As with all moving averages, the total length of the moving average determines the time frame for the system. A system that uses a 5-day EMA and a 35-day EMA would be considered short-term. A system using a 50-day SMA and a 200-day SMA would be considered to be medium-term, possibly even long-term.
Two Type Of Double Crossover
- Bullish crossover / Golden Cross
- Bearish crossover / Dead Cross