# AdaptiveRSiMt5

The Relative strength index is an oscillator that follows price, it was introduced by Welles Wilder, who went on to recommend the 14 period RSI. This adaptive version is based on the indicator described by John Ehlers, in the book 'Rocket Science for Traders'. The indicator uses the homodyne descriminator to compute the dominant cycle.

To apply the homodyne descriminator, real and imaginary parts have to be calculated from the Inphase and Quadrature components. (Inphase and Quadrature components are deduced using the Hilbert transform. To learn more about this, read the article on Advanced adaptive Indicators theory and implementation. The sections on Complex numbers and phasors for measuring market cycles and also Measuring cycle period.) To achieve this the product of the current Inphase component and its value a bar ago are added to the product of the current Quadrature component and its value one bar ago to produce the real part. For the imaginary part, the product of the current Quadrature component and the value of Inphase component a bar ago is taken away from the product of the current Inphase component and the value of the Quadrature component a bar ago. Both real and imaginary parts are then smoothed, before the cycle period can be deduced.

The cycle is calculated by taking the arctangent of the imaginary part divided by the real part. Restrictions are placed so as to make sure that the rate of change of the cycle period is limited to +-50% of the previous cycle period and further more, the resulting cycle period is limited to being greater than 6 and less than 50. Smoothing is then applied for the last time on the cycle period.

This cycle period value is then used at each bar close as the value that represents the number of bars back to be analyzed for producing the Relative strength indicator. This enables the adaptive nature of the indicator.

It can be used as an alternative to the conventional Relative strength index. You do not need to worry about setting periods.

**Indicator Parameters: **

- The limits value controls the number bars the indicator will be drawn for.
- The cyclepart is a modifier for the calculated cycle period, it helps to make sure that the indicator remains in phase with the price data. The figure can also be used to optimize the indicator for the measured cycle.

Rodrigo da Silva Boa2016.03.12 21:34 #用户没有留下任何评级信息