Moving Average Calculator — Formula
## How to Calculate a Simple Moving Average
### Formula
**SMA(n) = (v1 + v2 + ... + vn) / n**
The simple moving average smooths data by averaging the most recent n observations. As new data arrives, the oldest point drops off and the newest is added. SMA reduces noise and reveals underlying trends in time-series data.
### Formula
**SMA(n) = (v1 + v2 + ... + vn) / n**
The simple moving average smooths data by averaging the most recent n observations. As new data arrives, the oldest point drops off and the newest is added. SMA reduces noise and reveals underlying trends in time-series data.
Esempio Risolto
Daily sales: 10, 12, 15, 14, 18. Calculate the 5-day moving average.
- Sum = 10 + 12 + 15 + 14 + 18 = 69
- 5-period SMA = 69 / 5 = 13.8
- 3-period SMA (last 3) = (15 + 14 + 18) / 3 = 15.6667