How to Calculate Simple Moving Average
A moving average is a method used to smooth data that have a high level of variance or volatility. The smoothed data can be used to show trends that might be hidden by the erratic nature of the raw data. Moving averages commonly are used in financial applications and are one tool used to assess the technical strength of a stock or other investment instrument. Many financial programs automatically calculate the moving average curves for a given stock chart, and moving averages can be programmed into spreadsheets, but they also can be calculated by hand, if necessary.
Instructions
-
-
1
Define the window you want to use to calculate your moving average. Thirty-day and 90-day moving averages are common in the investment industry.
-
2
Gather the data currently available for the window you have defined. This can be daily data, hourly data or even real-time data. The more refined the data, the more difficult it will be to calculate the moving average without a spreadsheet or some other computer program.
-
-
3
Calculate the average of the data you have collected. A simple average is defined as the sum of all the data divided by the total number of data points.
-
4
Add the next available data points to the data set when it becomes available. At the same time, remove the first data point from the set. This way, there always will be the same number of data points in the data set. For example, in a 30-day moving average, all the data for the 31st day is added as all the data for the first day is removed, leaving 30 days' worth of data in the data set.
-
5
Take the average of the new data set. If you are plotting the moving average on a graph, this will be the second data point.
-
6
Repeat the process as new data become available for as long as is necessary for your application.
-
1