A simple moving average is the arithmetic mean of a fixed number of observations. An exponential moving average gives more weight to recent observations. Both summarize past prices. Neither can identify a new trend without some delay or false signals.
A trend filter might allow long setups only above an average. Specify the sampling period, price input and whether the condition is checked at a closed bar. Test the filter’s net effect after costs; making a chart cleaner does not automatically improve a strategy.
Worked example
For closes of 10, 12 and 14, the three-period simple moving average is 12. When the next close is 16, the rolling average becomes 14 because the oldest observation drops out.
Check your understanding
What is the three-period SMA for 8, 10 and 12?
Show explanation
10. It is a summary of those three observations, not a forecast.
Progress is stored on this device.