Ehlers Sinewave Indicator [CC]

Dilihat 1366
The Sinewave Indicator was created by John Ehlers (Rocket Science For Traders pgs 97-99) and this is a few indicators in one. Simply put it is a leading indicator which you don't see too many of those these days. If the blue line crosses over the red line then within the next few bars the price will start an uptrend and if the blue line crosses below the red line then in the next few bars it will start a downtrend. I have also included an immediate buy and sell signal on the 0 line which is green when you should buy and red when you should sell.

Let me know if you would like to see any other scripts or if you want something custom done!
Catatan Rilis: made changes to fix errors in the source book
Catatan Rilis: fixed a typo
Catatan Rilis: fixed a typo

Komentar

your scripts are nice and having solid re-search. if you don't mind can i request you to make some study based on adxcellence book also .
Jawab
@daytraderph, yes just send me a private message
Jawab
Please check lines 46 to 50 and the errata. Check also my Sine Wave if you wish. " "
Jawab
sal157011
@sal157011, those were changed already to match the errata you sent. what is the issue?
Jawab
Good idea.
Jawab
Midhunsekhar87
@Midhunsekhar87, thank you!
Jawab
The code on the Book Rocket Science for traders and other books by John Ehlers have some errors.
Once he published an errata on his site Mesasoftware, but is not available anymore. Here is the errata on what concerns the sine wave.

pages 98 and 102 and 116 and 120 & 121: the code should be corrected to be:
....... RealPart = RealPart + Sine(360*count/DCPeriod)*(SmoothPrice);
....... ImagPart = ImagPart + Cosine(360*count/DCPeriod)*(SmoothPrice);
....... If AbsValue(ImagPart) > 0 then DCPhase = Arctangent(RealPart/ImagPart);
....... If AbsValue(ImagPart) <= .001 then DCPhase = DCPhase + 90*Sign(RealPart):

If you wish check my script "Sine Wave" for what I think is the correct version of sine wave.
Jawab
sal157011
@sal157011, do you happen to have a copy of the errata?
Jawab
cheatcountry
@cheatcountry, Unfortunately I only have the first version of the errata, there was another more recent version but I didn't save it. Here it is what I've got: Note: this comments editor turns square brackets into round brackets.
------------------------------
As many times as the book was editied, some errors still got through. Here are the new corrections:
page 25: the correct equation is WMA = (4*Price + 3*Price + 2*Price + Price)/10;

page 56: the lag of the Hilbert Transform is 7 bars.

page 80: Figure 8.1 (a) and (b) are reversed.

pages 98 and 102 and 116 and 120 & 121: the code should be corrected to be:
....... RealPart = RealPart + Sine(360*count/DCPeriod)*(SmoothPrice);
....... ImagPart = ImagPart + Cosine(360*count/DCPeriod)*(SmoothPrice);
....... If AbsValue(ImagPart) > 0 then DCPhase = Arctangent(RealPart/ImagPart);
....... If AbsValue(ImagPart) <= .001 then DCPhase = DCPhase + 90*Sign(RealPart):
page 175: Figure 16.3 The fourth line from the end should corrected to be:
....... > Low and Close < High - (High -
page 183: Figure 17.1. The word "Speed" should be replaced with "FastLimit"
page 212: Figure 20.4. The code should be corrected to be:
....... Trigger = (4*Predict + 3*Predict + 2*Predict + Predict) / 10;
Jawab
sal157011
@sal157011, I made those changes. Can you send me via pm the errata file you have?
Jawab