Ehlers Even Better Sinewave syntax

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #118835 quote
    nonetheless
    Participant
    Master

    Hello very brainy and esteemed colleagues,

    I would like to incorporate the Ehlers Even Better Sinewave in my strategy and I’ve got as far as

    indicator4 = CALL “Ehlers Even Better Sinewave”[50,.8, -.8]

    but what I ultimately need is something like:

    c13 = (SineWave > -8)
    c14 = (SineWave < .8)

    So I assume I need something linking SineWave to indicator4 … but how do I do that?

    #118840 quote
    robertogozzi
    Moderator
    Master

    Is that what you want?

    c13 = (indicator4 > -8)
    c14 = (indicator4 < .8)
    #118844 quote
    nonetheless
    Participant
    Master

    That was the first thing I tried but I get an error saying “Ehlers Even Better Sinewave returns 4 values but your code needs 1”.

    As far as I can see, the 4 values associated with that indicator seem to be SineWave, Level Up, Level Down and Mid Level, so I assume that SineWave is the one that I want, no?

    #118850 quote
    Nicolas
    Keymaster
    Master

    Probably…! But you should refer to the returned values of the Sinewave indicator, you get the called variables in the same order than in the RETURN instruction of the indicator.

    You could also have a look in the documentation: CALL to get a better understanding on how to use CALL.

    nonetheless thanked this post
    #118854 quote
    nonetheless
    Participant
    Master

    Thanks @Nicolas for pointing me in the right direction! (like, duh, try reading  the manual)

    For anyone else who may be interested, it works like this:

    Sinewave, ignored, ignored, ignored = CALL "Ehlers Even Better Sinewave"[50,.8, -.8]
    c13 = (Sinewave > -8)
    c14 = (Sinewave < .8)

    So now we know.

    #118859 quote
    Nicolas
    Keymaster
    Master

    just RTFM! 😆

    nonetheless thanked this post
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.

Ehlers Even Better Sinewave syntax


ProOrder: Automated Strategies & Backtesting

New Reply
Author
Summary

This topic contains 5 replies,
has 3 voices, and was last updated by Nicolas
6 years ago.

Topic Details
Forum: ProOrder: Automated Strategies & Backtesting
Language: English
Started: 02/06/2020
Status: Active
Attachments: No files
Logo Logo
Loading...