|
MOVING AVERAGES: THE INS AND OUTS OF
By David Landry
The moving average is probably
one of the most used and possibly overused indicators
in the financial markets. In the first of this
three-part series we will look at the calculation and
comparison of simple, exponential and weighted moving
averages.
Simple Moving Average
An average is simply the sum
of a data set divided by the number of data points.
Let's look at a set of grades. Suppose Johnny earns
the following grades:
67 77 80 82 85
His average would be the sum of the grades divided by the number of tests:
(67 + 77 + 80 + 82 + 85)/5 = 391/5 = 78.20
Now suppose on his next test he scores a 90. If we took a 5-day "moving"
average of his grades we would drop off his oldest
grade (67) and add in his newest grade (90) and then
divide by 5. This is illustrated in Figure 1. Notice
how the average "moves" from the oldest 5
data points to the newest 5 data points, hence the
name "moving average."
|
Figure 1:
A 5-Period Simple Moving Average. Notice how
the average "moves" from the oldest
5 periods to the newest 5 periods.
|
Exponential Moving Average
An Exponential Moving Average
(EMA) takes a percentage of today's price and adds in
the prior day's exponential moving average times 1
minus that percentage. For instance, suppose you
wanted a 10% EMA. You would take today's price and
multiply it by 10% then add that figure to the prior
day's EMA multiplied by the remaining percent:
(today's close * .10) + (yesterday's exponential moving average * (1-.10))
Because most people think in
terms of days (time periods) versus percentages, the
following formula can be used to determine the
percentage to be used in the calculation:
Exponential Percentage = 2 /(Time Periods + 1).
So if you wanted a 20 period
EMA you would use 9.52% (2/(20+1)) as your percentage
for the calculation.
As usual, I strongly suggest
that you have a computer do all the work, since
the EMA is available in virtually all charting
packages. I have yet to meet a trader that does these
calculations by hand. As you can see, by nature of
its calculation, the EMA gives more weight to the
recent periods. This brings us to our next type of
moving average: the weighted moving average.
Weighted Moving Average
The theory behind a weighted
moving average (WMA) is that the recent data is more
relevant than past data. Therefore, it puts more
"weight" on the recent data and less weight
on the older data. To calculate it, you take the
number of periods you wish to analyze and that
becomes the weight for today's price. Yesterday's
price would use today's weight -1 and so on and so
forth for the number of periods. You then divide the
sum of the weighted prices by the sum of the weights.
For example, suppose we took
the last five "grades" we used in our first
example and calculated a 5-period WMA. The
calculation would be as follows:
|
Figure 2:
Calculation of a Weighted Moving Average. The
number of periods (in this case 5) becomes
the "weight" for today. The weight
for the remaining days is reduced by 1 until
the last day is found. Therefore, the most
recent period gets the highest weight and the
oldest period gets the smallest. The summed
weighted prices are then divided by the sum
of the weights
|
Again, I strongly suggest that you have your computer do all the work.
Comparing the EMA,WMA and
Simple Moving Averages
The simple moving average
gives equal weight to all data points. By nature, it
is the "true" average. The exponential and
weighted moving averages give the most recent data
points the highest rankings or
"weightings". Therefore, the simple moving
average tends to lag (by representing all data points
equally) the exponential and weighted moving averages
during large price changes. However, during
"normal" or "flat" markets the
differences become negligible. This is illustrated in
figure 3.
|
Figure 3:
March 2000 Bonds with 50-day Simple,
Exponential and Weighted Moving Averages.
Notice during "normal" or
"flat" markets the averages tend to
run together (a). However, once the market
begins to make sharp moves (b) and (c) the
EMA and WMA tends to catch up to price faster
while the Simple Moving Average tends to lag.
|
So Which One Should You Use?
Deciding between the types of
moving averages really becomes a matter of personal
preference. Normally when you hear talk of moving
averages, in the media it normally refers to simple
moving averages. Therefore, due to widespread focus
on these numbers, it's important to give them
consideration. The 50- and 200-day (simple) moving
averages are most commonly used here. As a trader,
especially during large price moves, you might
consider experimenting with exponential or weighted
moving averages.
Looking Ahead
Now that we've defined the
different types of moving averages we can focus on
characteristics of the indicator and strategies. In
part two we'll look at these characteristics and
general uses of moving averages. We'll touch upon the
fact that "conventional wisdom" regarding
moving averages is often wrong. Finally, in part
three we'll look at specific strategies and set-ups
involving moving averages.
More Insightful articles at:

|