What's New:
Recent Quotes:
November 22, 2009 5:38:24 AM EST

Technical Analysis

Var. Moving Average (VMA)

VMA allows you to get very creative with the moving averages. You may specify the length, type, (exponential, normal, or smoothed) and price for each moving average. You may specify 1, 2, or 3 distinct moving averages. These moving averages may overlay the bar chart or display individually.

The moving average crossover buy/sell signals are as follows. A buy signal is flashed when the short and intermediate term averages cross from below to above the longer term average. Conversely, a sell signal occurs when the short and intermediate term averages cross from above to below the longer term average.

You can use the crossover approach with only two moving averages, however market technicians suggest using longer term averages, i.e., longer intervals, when trading only two moving averages in a crossover system.

Another approach is to use closing prices with the moving average(s). When the closing price is above the moving average(s), you maintain a long position. If the closing price falls below the moving average, you liquidate any long position and establish a short position.

Remember, any moving average system works best in trending markets. If you would like to read more about moving averages and optimized parameters, you should read Technical Analysis in Commodities by P.J. Kaufman. The optimization studies were performed between 1970 and 1976 by a large brokerage firm. The book also details other studies available within Technical.

Parameters:
  • Period1 (5) - the number of bars, or period, used to calculate the first moving average
  • Period2 (10) - the number of bars, or period, used to calculate the second moving average
  • Period3 (20) - the number of bars, or period, used to calculate the third moving average.
Computation

The formulae to calculate a normal, exponential, and smoothed moving average are below. The normal moving average is:
Mat = (P1 +... + Pn) / n
  • Mat is the simple moving average for the current period.
  • Pn is the price for the nth interval.
  • n is the length of the moving average.
FutureSource computes the average of the past n intervals using the price specified for that period. Remember, you specify the price. It can be the open, high, low, close, midpoint, or average price.

The exponential moving average is:
EMAt = EMAt-1 + (k * (Pt - EMAt-1))
  • EMAt is the exponential moving average for the current period.
  • EMAt-1 is the exponential moving average for the previous period.
  • Pt is the price for the current interval.
  • K is the exponential smoothing constant.
FutureSource does not use an assigned weight (smoothing constant) to compute the exponential moving average. Instead, it asks you to specify the length of the moving average. You can then determine the weight from the formula listed below.

If you specify a moving average length of 10, the smoothing constant is 0.18. Here is how to determine the smoothing constant.
k = 2 / (n + 1)
  • k is the smoothing constant.
  • n is the length of the moving average.
Now, substitute the values in the formula.
k = 2 / (10 + 1)
= 2 / 11
=.1818
Conversely, if you know the smoothing constant, you must derive the length of the moving average. In this example, use a smoothing constant of .125. You can solve the above equation for the value of n, which produces the following formula:
n = (2 / k) - 1
Now, substitute the above values in the equation.
n = (2 /.125) - 1
= 16 - 1
= 15
Please remember that FutureSource always asks for the length of moving average, not the smoothing constant. If you know the smoothing constant, use the above formula to determine the length of the moving average. If you know the length of the moving average and want to know the smoothing constant, use the formula to solve for the smoothing constant or k.

The smoothed moving average is:
Mat = ( (Mat-1 * (S-1)) + Pt ) / S
  • Mat is the moving average for the current period.
  • Mat-1 is the moving average for previous period.
  • Pt is the price for the current interval.
  • S is the period for smoothing.
Note: You may find variations of the above formula.

Trading Corner