Moving averages are primarily used by traders for defining the trend and for trading signals, although they are not at all necessary at both cases. Everyone who has seen charts and has little knowledge of technical analysis, can define trend with naked eye within a second. On the other hand they are very useful for defining trend on computerized systems due to their mathematical structure. Also it is not optimal to be used as trading signals without confirmation from other technical criteria and especially real supports or resistances.
In trading there are two main kinds of moving averages, the simple moving average and the exponential. The simple moving average is equal weights all the numbers that is consisted of, whereas the exponential moving average gives more weight on the last observations, so in that sense it is more responsive than the simple moving average and reacts quicker to price changes. In trading both of them are used and there is no unanimous decision which is best. In reality whichever someone uses, it is not making a big difference (excluding computerized trading).
Every day (if we refer to a daily moving average), the older observation is being deleted and it is replaced by the most recent in the recalculation of the moving average, hence the word ”moving”. Depending on the time frame of the chart we can automatically have the relevant moving average, i.e. in a 5 minutes chart the 20 periods moving average is the average of the 20 latest 5 minutes periods.
The smaller the moving average the most it resembles the price movement. Notice in the daily chart of JPM below that the red 10 days moving average is much closer to the price than the blue 30 days moving average.
At point 1 the 10 days moving average breaks downwards the 30 days moving average, making a crossover. For many traders when a smaller moving average breaks downwards a bigger one it is generally a sell or short sell signal and when it breaks the bigger one upwards it is a buy signal.
Moving averages are working only in trending charts, whereas in sideways movement they give many false signals (whipsaws). The use of a moving average for trading requires study of the particular stock chart in order to discover which moving averages (5, 10, 50 periods) produce better signals or in other words which of them the stock ”respects”.
Many traders reject their usefulness as trading signals on the base that they might operate like a self fulfilling prophecy. Self fulfilling prophecies make otherwise irrelevant and non influential technical indicators to work, just because many traders follow them and not because they have any forecasting power.
Also in many cases they act like supports or resistances because price tend to stop at the price levels they express, no matter what is the real reason behind this fact. The 200 days moving average is maybe the most famous for this property as many times in downtrends price stops declining near it (SPY daily chart below), or in uptrends price stops ascending near it and reverses back.
They lag considerably real price movement (depending on their time period), so following them doesn’t allow small stops and wide profit targets, at least relatively to reversal strategy.
Conclusively, they can be used only as additional indicators and not as primary trading signals, at least for human traders and they are not at all a mandatory prerequisite in successful trading decisions. Maybe the best use is to watch them in order to have a clue about what computers algorithms and other traders might do in case of crossovers.