Rise Fall ATR MT4
- Indicators
- Yu Zhang
- Version: 1.0
- Activations: 20
1. What is this
Rising volatility and falling volatility are not the same, whether it is academic research or actual testing has shown this point.
The original ATR indicator is calculated by putting up and down fluctuations together. This indicator is to calculate separately the upward volatility and the downward volatility, which can better help you study the market.
2. Indicator description
There are two modes for the calculation of this indicator, as shown in the following table:
0 | 1 | 2 | 3 | 4 | 5 | |
Direction | + | - | + | + | - | + |
TureRange | 15 | 20 | 17 | 5 | 16 | 8 |
ATR | (15+20+17+5+16+8)/6=13.5 | |||||
Mode1 | Do not fill the position with 0, the period will change | |||||
Mode1_Rise_TR | 15 | 17 | 5 | 8 | ||
Mode1_Fall_TR | 20 | 16 | ||||
Mode1_Rise_ATR | (15+17+5+8)/4=11.25 | |||||
Mode1_Fall_ATR | (20+16)/2=18 | |||||
Mode 2 | Fill the position with 0, the period does not change | |||||
Mode2_Rise_TR | 15 | 0 | 17 | 5 | 0 | 8 |
Mode2_Fall_TR | 0 | 20 | 0 | 0 | 16 | 0 |
Mode2_Rise_ATR | (15+0+17+5+0+8)/6=7.5 | |||||
Mode2_Fall_ATR | (0+20+0+0+16+0)/6=6 |
As shown in the table above. For example, in a sequence with a period of 6, there are 4 ups and 2 downs. Mode 1 does not fill the position with 0, so the period of ups and downs are changed to 4 and 2 respectively. Mode 2 fills the position with 0, so the period of ups and downs remains the same.
Mode 1 only uses SMA for averaging calculation. Mode 2 can be calculated by a variety of averaging methods because the period is unchanged.
3. Instructions for use
Parameter Description:
- InpAtrPeriod = 21; // ATR period
- InpAllowZeroTR = false; // Whether to allow zero true range.
- InpMAMethod = MODE_SMA; // If the above is true(allow zero TR), you can choose ATR Method.
There are 3 results: Rise_ATR, Fall_ATR, Total_ATR. Among them, Total_ATR is the ATR result that does not distinguish between ups and downs.
4. Other
This indicator has MT4 version and MT5 version