
Averages can be placed through the high and low. When prices close beyond both lines a trend may start. Exits can be taken when the price closes back beyond the previous average.

The CQG Moving Average study plots the average price over a user-specified period in bars. Five methods of calculating the Moving Average are available in CQG/Windows - Simple, Smoothed, Centered, Weighted and Exponential.

Simple:
For the following example the PERIOD equals 3.
The first value for a Simple Average is determined by formula SIMPLE. It is plotted on the chart at the third bar from the left side of the screen.
SIMPLE = (PRICE 1 + PRICE 2 + PRICE 3)/PERIOD
The next value would be plotted at the fourth bar from the left side of the screen.
SIMPLE = (PRICE 2 + PRICE 3 + PRICE 4)/PERIOD
Eliminating the oldest PRICE from the calculation, and including the next more recent PRICE, determines subsequent values.
Smooth:
A Smoothed Moving Average is similar to a simple moving average. However, in a smoothed moving average, rather than subtracting the oldest value the previous smoothed average value is subtracted.
For the following example the PERIOD equals 3.
The first value for a Smoothed Moving Average is determined by the formula SMOOTH. It is plotted on the chart at the third bar from the left side of the screen.
SMOOTH =(PRICE 1 + PRICE 2 + PRICE 3)/PERIOD
The next value would be plotted at the fourth bar from the left side of the screen.
SMOOTH2 = (PREVIOUS SUM - PREVIOUS AVG + PRICE 4)/PERIOD
For the second calculation of SMOOTH, PREVIOUS SUM is the sum of PRICE 1 + PRICE 2 + PRICE 3; and PREVIOUS AVG is the initial value of SMOOTH.
The next value would be plotted at the fifth bar from the left side of the screen. SMOOTH = (PREVIOUS SUM - PREVIOUS AVG + PRICE 5)/PERIOD. Subsequent values would be determined by subtracting the PREVIOUS AVG from the PREVIOUS SUM, adding the next more recent PRICE, then dividing by the PERIOD.
Example: If the values 1,2,3,4 and 5 were reported for the first five bars the three-period smoothed moving averages for those bars would be calculated as follows:
|