Moving Average Envelopes
The Moving Average Envelopes function computes a pair of data bands that envelops a moving average of the input data values.
Each data band is positioned a percentage-based magnitude away from the moving average line. The average line can be calculated using a simple moving average or an exponential moving average. Applications of the Moving Average Envelopes function include indication of overbought/oversold conditions and price trends for a security.
The MOVAVGEVPUPPER and MOVAVGEVPLOWER functions require the following input:
- d0 - Input data values - The set of data values for which the MOVAVGEVPUPPER and MOVAVGEVPLOWER formulas are calculated.
The MOVAVGEVPUPPER and MOVAVGEVPLOWER functions require the following parameters.
- s0 - Moving Average Type - The type of moving average to use in the calculation. Valid values are:
- 0 : Simple Moving Average (default)
- 1 : Exponential Moving Average
- s1 - Period - The number of time periods to use in the calculation. Default value is 10.
- s2 - Standard Deviation Shift - The number of standard deviations that is used to shift the bands away from the simple moving average. Default value is 2.5.
The MOVAVGEVPUPPER function generates the following output:
- Upper Envelope - The Upper Envelope result set.
The MOVAVGEVPLOWER function generates the following output:
- Lower Envelope - The Lower Envelope result set.