All John Ehlers Indicators... - page 60

Wayne
20
Wayne  

Could any one please post an MTF LaGuerre RSI with Alerts on crosses. A big thank you to all the great contributors of the thread.

Mladen Rakic
201585
Mladen Rakic  
Pips4Fun:
Could any one please post an MTF LaGuerre RSI with Alerts on crosses. A big thank you to all the great contributors of the thread.

What types of crosses?

There are some laguerre RSI indicator at this thread : https://www.mql5.com/en/forum/173022 or at this thread : https://www.mql5.com/en/forum/180648 that might be what you are looking for

nigelphilpott99
26
nigelphilpott99  
Nigel99:
Thank you very much for those replies. I am just trawling through Mr Ehler's latest book. On another tack, near the end of the book, he states that "the inverse fisher transform of the adaptive stochastic indicator gives clear and unambiguous indications of proper buy and sell points"

The code is also given (in simple code format) as:

Step 1 the Adaptive stochastic indicator code is:

{

Adaptive Stochastic

(c) 2013 John F. Ehlers

}

Vars:

AvgLength(3),

M(0),

N(0),

X(0),

Y(0),

alpha1(0),

HP(0),

a1(0),

b1(0),

c1(0),

c2(0),

c3(0),

Filt(0),

Lag(0),

count(0),

Sx(0),

Sy(0),

Sxx(0),

Syy(0),

Sxy(0),

Period(0),

Sp(0),

Spx(0),

MaxPwr(0),

DominantCycle(0);

Arrays:

Corr[48](0),

CosinePart[48](0),

SinePart[48](0),

SqSum[48](0),

R[48, 2](0),

Pwr[48](0);

//Highpass filter cyclic components whose periods are shorter than 48 bars

alpha1 = (Cosine(.707*360 / 48) + Sine (.707*360 / 48) - 1) / Cosine(.707*360 / 48);

HP = (1 - alpha1 / 2)*(1 - alpha1 / 2)*(Close - 2*Close[1] + Close[2]) + 2*(1 - alpha1)*HP[1] - (1 - alpha1)*(1 - alpha1)*HP[2];

//Smooth with a Super Smoother Filter from equation 3-3

a1 = expvalue(-1.414*3.14159 / 10);

b1 = 2*a1*Cosine(1.414*180 / 10);

c2 = b1;

c3 = -a1*a1;

c1 = 1 - c2 - c3;

Filt = c1*(HP + HP[1]) / 2 + c2*Filt[1] + c3*Filt[2];

//Pearson correlation for each value of lag

For Lag = 0 to 48 Begin

//Set the averaging length as M

M = AvgLength;

If AvgLength = 0 Then M = Lag;

Sx = 0;

Sy = 0;

Sxx = 0;

Syy = 0;

Sxy = 0;

For count = 0 to M - 1 Begin

X = Filt[count];

Y = Filt[Lag + count];

Sx = Sx + X;

Sy = Sy + Y;

Sxx = Sxx + X*X;

Sxy = Sxy + X*Y;

Syy = Syy + Y*Y;

End;

If (M*Sxx - Sx*Sx)*(M*Syy - Sy*Sy) > 0 Then Corr[Lag] = (M*Sxy - Sx*Sy)/SquareRoot((M*Sxx - Sx*Sx)*(M*Syy - Sy*Sy));

End;

For Period = 10 to 48 Begin

CosinePart[Period] = 0;

SinePart[Period] = 0;

For N = 3 to 48 Begin

CosinePart[Period] = CosinePart[Period] + Corr[N]*Cosine(360*N / Period);

SinePart[Period] = SinePart[Period] + Corr[N]*Sine(360*N / Period);

End;

SqSum[Period] = CosinePart[Period]*CosinePart[Period] + SinePart[Period]*SinePart[Period];

End;

For Period = 10 to 48 Begin

R[Period, 2] = R[Period, 1];

R[Period, 1] = .2*SqSum[Period]*SqSum[Period] + .8*R[Period, 2];

End;

//Find Maximum Power Level for Normalization

MaxPwr = .995*MaxPwr;

For Period = 10 to 48 Begin

If R[Period, 1] > MaxPwr Then MaxPwr = R[Period, 1];

End;

For Period = 3 to 48 Begin

Pwr[Period] = R[Period, 1] / MaxPwr;

End;

//Compute the dominant cycle using the CG of the spectrum

Spx = 0;

Sp = 0;

For Period = 10 to 48 Begin

If Pwr[Period] >= .5 Then Begin

Spx = Spx + Period*Pwr[Period];

Sp = Sp + Pwr[Period];

End;

End;

If Sp 0 Then DominantCycle = Spx / Sp;

If DominantCycle < 10 Then DominantCycle = 10;

If DominantCycle > 48 Then DominantCycle = 48;

//Stochastic Computation starts here

Vars:

HighestC(0),

LowestC(0),

Stoc(0),

SmoothNum(0),

SmoothDenom(0),

AdaptiveStochastic(0);

HighestC = Filt;

LowestC = Filt;

For count = 0 to DominantCycle - 1 Begin

If Filt[count] > HighestC then HighestC = Filt[count];

If Filt[count] < LowestC then LowestC = Filt[count];

End;

Stoc = (Filt - LowestC) / (HighestC - LowestC);

AdaptiveStochastic = c1*(Stoc + Stoc[1]) / 2 + c2*AdaptiveStochastic[1] + c3*AdaptiveStochastic[2];

Plot1(AdaptiveStochastic);

Plot2(.7);

Plot6(.3);

Step 2 to implement the inverse fisher transform on the adaptive stochastic indicator:

Vars:

IFish(0) ;

Value1 = 2*(AdaptiveStochastic - .5) ;

IFish = (ExpValue(2*3*Value1) - 1) / (ExpValue(2*3*Value1) + 1) ;

Plot1(IFish) ;

Plot4(.9*IFish[1]) ;

Step 3 Adding buy sell signals:

A trigger line is added which is the Fisher transform delayed by one bar and attenuated to 90 percent.

Step 4 A development added by me:

If possible a variant of the above (Inverse Fisher adaptive Stochastic indicator) should be developed which is MTF so that higher time-frame versions can be displayed also.

I think these 2 indicators the Inverse Fisher adaptive Stochastic indicator and the MTF Inverse Fisher adaptive Stochastic indicator would be potentially very interesting indicators to test if anyone is please able to produce in MT4 ?

Best Regards

Nigel

Dear Mladen,

I just wondered if you believed this to be possible or worthwhile ?

Regards

Nigel

hughesfleming
273
hughesfleming  

Just my opinion here Nigel,

It is the 48 bar period limit that is going to kill you. If you look at the cycle extraction thread you will find tools to help you. The strongest cycles are a lot longer than 48 bars. Ehlers has this tendency to view longer period lengths as trends. He did the same thing with his Corona charts and everyone wonders why they don't work very well.

I think you are on the right track but this might not be the place to look.

Kind regards,

Alex

Edit: I would start by studying the Goerzel browser in the advanced Elite section and then manually tuning indicators to see how they react to different period lengths. I think this would be a better place to start than jumping head first into adaptive indicators. There is also a section on "Lookback indicators" that will be helpful.

Wayne
20
Wayne  
mladen:
What types of crosses? There are some laguerre RSI indicator at this thread : https://www.mql5.com/en/forum/173022 or at this thread : https://www.mql5.com/en/forum/180648 that might be what you are looking for

It's kind of you to respond MLaden. And I notice that you wrote the two copies I currently use - great credit to you.

I'm looking for one with alerts for gamma crosses in the indicator separate window and which is also MTF. I'm looking through the links you suggested but haven't found any such as yet.

I upload a nice version herewith that is MTF, but has no gamma alerts - maybe someone a little less busy can write an alert into it.

Thanks again mladen.

Mladen Rakic
201585
Mladen Rakic  
Pips4Fun:
It's kind of you to respond MLaden. And I notice that you wrote the two copies I currently use - great credit to you.

I'm looking for one with alerts for gamma crosses in the indicator separate window and which is also MTF. I'm looking through the links you suggested but haven't found any such as yet.

I upload a nice version herewith that is MTF, but has no gamma alerts - maybe someone a little less busy can write an alert into it.

Thanks again mladen.

Pips4Fun

For start, I think you should use the version posted here : https://www.mql5.com/en/forum/178416/page21 (it is new metatrader 4 compatible). Also, I assume that you mean some level crossings (since, after all, that is a RSI). Am I right?

Wayne
20
Wayne  
mladen:
Pips4Fun For start, I think you should use the version posted here : https://www.mql5.com/en/forum/178416/page21 (it is new metatrader 4 compatible). Also, I assume that you mean some level crossings (since, after all, that is a RSI). Am I right?

Ah, wonderful! Many many thanks.

Yes, I do mean level crossings (user settable). Ermmm........ I couldn't trouble you with the request for it, could I? Either way, thanks a lot for your assistance.

Best regards.

krzysiaczek99
298
krzysiaczek99  
hughesfleming:
Just my opinion here Nigel,

It is the 48 bar period limit that is going to kill you. If you look at the cycle extraction thread you will find tools to help you. The strongest cycles are a lot longer than 48 bars. Ehlers has this tendency to view longer period lengths as trends. He did the same thing with his Corona charts and everyone wonders why they don't work very well.

I think you are on the right track but this might not be the place to look.

Kind regards,

Alex

Edit: I would start by studying the Goerzel browser in the advanced Elite section and then manually tuning indicators to see how they react to different period lengths. I think this would be a better place to start than jumping head first into adaptive indicators. There is also a section on "Lookback indicators" that will be helpful.

Length 48 can be optimized and changed, personally i tried the length up to 400 on 1 min chart.

This what he is calling 'roofing filter' is just band pass filter which passes the cycles in length

48-10 for example, this idea he started in 90ties to use it for trading, now it's just a new name.

Anyway I evaluated roofing filter and super smoother quite deeply. I have a AI system with 170

inputs so I tried 1st to smooth input series before preprocessing by SS than by roofing filter.

In 1st case profit factor was the same like without smoothing, in 2nd case PF

was ALWAYS LOWER than for raw data.

Than I had a deeper look at behaviour of roofing filter itself and discovered that it has very

strong tendency to overshoot, just plot it together with e.g. RSI and you will see what I mean.

This is very unwanted behavior which introduces extra noise and whispaw trades.

So most likely this and cutting off longer cycles was causing profit factor to fall. This system makes several thousands trades so results are significiant

Krzysztof

hermes
505
hermes  

Hilbert Sine Wave...

Hi fellow traders, could somebody help me find an original Hilbert Sine Wave indicator which will work on the new MT4/5? Those found on TSD (MLaden's) forum don't show up in navigator.

Thank for help.

Hermes

P.S. and the same problem with Coppock's indicator.

Mladen Rakic
201585
Mladen Rakic  
hermes:
Hi fellow traders, could somebody help me find an original Hilbert Sine Wave indicator which will work on the new MT4/5? Those found on TSD (MLaden's) forum don't show up in navigator.

Thank for help.

Hermes

P.S. and the same problem with Coppock's indicator.

Hermes

Which indicator exactly are you trying to use? I am trying to recall but somehow I do not remember making a sine wave indicator nor can I find one on my PC