A *weighted moving average* is calculated by defining *weight
factors*, *W*_{1}, *W*_{2},... *W*_{n},
for each day in the *n* day
moving average. The weighted moving average for day *d*
is then:

Note that if all the weights, *W*_{i} are 1,
this equation reduces to that of a simple moving average.

By John Walker