John Ehlers Optimal Tracking Filter

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #110362 quote
    Matriciel
    Participant
    Master

    Bonjour Nicolas,

    Price = (High+Low)/2
     
    if(barindex>5) then
    Value1 = .2*(Price - Price[1]) + .8*Value1[1]
    Value2 = .1*(High - Low) + .8*Value2[1]
    if (Value2 <>0) then 
    lambda = Abs(Value1 / Value2)
    endif
     
    alpha = ( -lambda*lambda + SQRT(lambda*lambda*lambda*lambda + 16*lambda*lambda)) /8
    Value3 = alpha*Price + (1-alpha)*Value3[1]
    endif
     
    RETURN Value3 as "Tracking filter"

     

    Comment peut-on faire pour avoir cette “Moyenne Mobile” d’une autre période ?
    Par exemple ; je suis sur un graphique 5 minutes et je voudrais avoir cette “Moyenne Mobile” du graphique d’une heure.
    Bien à toi.

    #110363 quote
    Matriciel
    Participant
    Master

    J’ai essayé de cette façon mais cela ne fonctionne pas :

    Price = ((High+Low)[12])/2
     
    if(barindex>5) then
    Value1 = .2*(Price - Price[1]) + .8*Value1[1]
    Value2 = .1*((High - Low)[12]) + .8*Value2[1]
    if (Value2 <>0) then 
    lambda = Abs(Value1 / Value2)
    endif
     
    alpha = ( -lambda*lambda + SQRT(lambda*lambda*lambda*lambda + 16*lambda*lambda)) /8
    Value3 = alpha*Price + (1-alpha)*Value3[1]
    endif
     
    RETURN Value3 as "Tracking filter"

    J’ai ajouté une période de 12 au (high + low)

    #110364 quote
    Nicolas
    Keymaster
    Master

    Pour mémoire, il n’existe pas encore de support MTF pour les indicateurs. Pour obtenir ce que tu veux, tu peux utiliser l’astuce des indicateurs avec GRAPH dans un backtest et l’instruction TIMEFRAME.

    Voir: Première approche sur le multi timeframe avec ProRealTime

    Matriciel thanked this post
    #110372 quote
    Matriciel
    Participant
    Master

    J’ai ajouté une moyenne mobile exponentielle de 50 périodes. Ca se rapproche pas mal du graphique 1 heure.

    Price = (High+Low)/2
     
    if (barindex>0) then
    Value1 = .2*(Price - Price[1]) + .8*Value1[1]
    Value2 = .1*(High - Low) + .8*Value2[1]
    if (Value2 <>0) then
    lambda = Abs(Value1 / Value2)
    endif
     
    alpha = ( -lambda*lambda + SQRT(lambda*lambda*lambda*lambda + 16*lambda*lambda)) /8
    Value3 = alpha*Price + (1-alpha)*Value3[1]
    endif
    
    Value31h = Exponentialaverage[50](Value3)
     
    RETURN Value3 coloured(0,0,0) style(line,1) as "Tracking filter", Value31h coloured(200,0,0) style(line,1) as "Tracking filter 1H"
Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.

John Ehlers Optimal Tracking Filter


ProBuilder : Indicateurs & Outils Personnalisés

New Reply
Author
author-avatar
Matriciel @matriciel Participant
Summary

This topic contains 3 replies,
has 2 voices, and was last updated by Matriciel
6 years, 4 months ago.

Topic Details
Forum: ProBuilder : Indicateurs & Outils Personnalisés
Language: French
Started: 10/17/2019
Status: Active
Attachments: No files
Logo Logo
Loading...