Moving averages are one of the most accessible tools of the technical analysis of stocks for investors and traders. Securities and stock market analysts often use the mnemonic “trend is your friend” to identify buy and sell points in short-term investment periods.
This is based on the assumption that a stock that goes up constantly is more likely to go up, and the one that goes down has a larger probability of constantly nosediving in the near future.
Having a clear view of trends can help an investor decide whether to sell, buy or hold a market position. However, determining a trend becomes difficult due to various reasons like rapid fluctuation or sudden increase/decrease in market activity.
This is where the metric of ‘moving averages’ comes in handy. A moving average is a technical indicator that tracks the securities’ price over a specific period and plots it on a line. A moving average essentially smooths out price fluctuations to give investors a general idea of where the trend is heading.
‘‘
Using moving averages to determine trends, an investor can better identify buy and sell signals.
What can you identify with moving averages?
Uptrend
- If a stock’s price value follows an upward tendency, where its recent high is higher than the previous high, and the recent low is higher than the previous low, then that stock is said to be in an uptrend.
Downtrend
- Contrary to an uptrend, a stock is said to be in a downtrend if its price values keep fluctuating on a downwards path, meaning that its current high is lower than the previous high and its current low is lower than the previous low.
Sideways trend
- Sideways trend occurs when the price of a security trades within a reasonably stable range without forming any distinct trends over time. In this trend, price action oscillates in a horizontal range or channel.
Significance of moving average
Examining a stock’s moving average based on current prices can help investors identify potential buy and sell signals. If the stock price is higher than the average price, it means that the trader is ready to buy the stock at a price higher than the average price. This shows that traders are optimistic about a surge in stock prices, indicating the opening for you to buy as well.
If the stock price is lower than its average price, it means that traders are ready to sell the stock at a price lower than the average price. This means that traders are frustrated with the volatility of stock prices. Therefore, sales opportunities should be sought.
The formula for moving average is:
Moving Average (MA) = Sum of stock prices in a particular period / Number of days (in the period)
Types of moving averages
Simple moving average (SMA)
The Simple Moving Average (SMA) calculates the average price of the selected price range based on the number of periods in the series, usually the closing price.
Let’s understand SMA with an example.
The closing prices of a stock for five days are as follows:
As per the formula, we need to calculate this:
(SP Day 1 + SP Day 2 + SP Day 3 + SP Day 4 + SP Day 5) / 5, (where SP = Stock Price).
Thus, the moving average of the stock price in this example would be:
=> MA = (55 + 56 + 55.5 + 52 + 56.02) / 5
=> MA = 274.52/5 = 54.904
Hence, the moving average of the stock price is Rs. 54.904.
A simple moving average weights all the data equally. Keep in mind that the longer the SMA, the slower it will react to recent price changes. After another trading day, the final closing price is added to the calculation and the first price expires (Rs. 55 in the above example).
Weighted moving average (WMA)
For the weighted moving average, the latest data points carry more weight. It is intended to show the latest changes in stock prices. The weights decrease consistently for each preceding period.
Example
The three data points recorded over three days are Rs. 50, Rs. 45, and Rs. 60. In WMA, weights are assigned to each number as per the latest day.
Since there are 3 periods, the most recent day (Rs. 60) gets the largest weight of 3, the second recent day (Rs. 45) receives a weight of 2, and the last day (Rs. 50) receives a weight of just 1.
Using the WMA formula, which is multiplying each data point’s price by its weighting factor and adding them, the calculation will go as follows:
=> [(3 x Rs. 60) + (2 x Rs. 45) + (1 x Rs. 50)]
=> 180+ 90 + 50 = 320.
The last step in WMA involves dividing the resulting value by the sum of the periods. The sum of the periods is 1+2+3 = 6.
=> WMA (180 + 90 + 50) / 6 = Rs. 53.33
Word of caution
Moving averages take a long time to reflect price changes. This is because the activity volume and transaction volume are assumed to be equal in all time periods. Moving averages cannot predict future performance, they only confirm established trends. Nevertheless, it is a powerful tool for the technical analysis of stocks and trends.