John Ehlers roofing filter

Forums ProRealTime English forum ProBuilder support John Ehlers roofing filter

Viewing 7 posts - 1 through 7 (of 7 total)
  • #33507

    Hi all,

    I was tring to replicate an indicator explained by John Ehlers in a youtube video.

    I attach the formula as image.

    When I try to code it on PRT I dont get any line, I presume is because the definition of Ehlers indicator at time t refers to the same indicator at time t-1:

    Indicator:

    a = (cos(0.707*360/48)+sin(0.707*360/48)-1)/cos(0.707*360/48)
    hp = 0

    hp = (1+a/2)*(1-a/2)*(close-2*close[1]+close[2])+2*(1-a)*hp[1]-(1-a)*(1-a)*hp[2]
    return hp

     

    Can someone help with that?

    MAny thanks

    Francesco

    #33516

    I guess I sorted this one by writing this

    a = (cos(0.707*360/48)+sin(0.707*360/48)-1)/cos(0.707*360/48)

    hp1 = (1+a/2)*(1-a/2)*(close[1]-2*close[2]+close[3])
    hp2 = (1+a/2)*(1-a/2)*(close[2]-2*close[3]+close[4])

    hp = (1+a/2)*(1-a/2)*(close-2*close[1]+close[2])+2*(1-a)*hp1-(1-a)*(1-a)*hp2
    return hp

     

    Do you agree?

    Many thanks

    Francesco

    #33560

    Francesco,

     

    ecco il codice

     

    1 user thanked author for this post.
    #33567

    Grazie mille Gabri!

    Saluti

    Francesco

    #33721

    Scusami Gabri ma continua a venire una linea pari a zero e basta, a te esce qualcosa di diverso?

    Grazie

    Francesco

    #33723

    problema risolto, grazie!..:)

    #40893

    Ok

Viewing 7 posts - 1 through 7 (of 7 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login