Three line break / Four line break

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #42671 quote
    Nico
    Participant
    Average

    Bonjour

    Je souhaite detecter le changement de trend avec une representation three line trade

    j’affiche donc 2 graph : le 1er en three line break (3) et le second en bougie avec l’indicateur ci dessous.

    On peut constater qu’a chaque changement de couleur de bougie du graph three line break , l’indicateur du 2nd graph change de sens

     

    once t=1
    once a0=(close)
    once a1=(close)
    once a2=(close)
    once a3=(close)
    
    
    if t=1 and close>a3 then
    a0=a1
    a1=a2
    a2=a3
    a3=close
    elsif t=1 and close<a0 then
    changement = - 1
    t=-1
    a1=a3
    a0=a3
    a3=close
    elsif t=-1 and close<a3 then
    a0=a1
    a1=a2
    a2=a3
    a3=close
    elsif t=-1 and close>a0 then
    changement =1
    t=1
    a1=a3
    a0=a3
    a3=close
    endif
     return changement coloured by t[1] as "cassure"
    

    Il fonctionne bien et m’indique chaque changement de couleur de bougie

     

    J’ai voulu essayer pour un four line break

    voici mon code

    once t=1
    once a0=(close)
    once a1=(close)
    once a2=(close)
    once a3=(close)
    once a4=(close)
    
    if t=1 and close>a4 then
    a0=a1
    a1=a2
    a2=a3
    a3=a4
    a4=close
    elsif t=1 and close<a0 then
    changement = - 1
    t=-1
    a1=a4
    a0=a4
    a4=close
    elsif t=-1 and close<a4 then
    a0=a1
    a1=a2
    a2=a4
    a4=close
    elsif t=-1 and close>a0 then
    changement =1
    t=1
    a1=a4
    a0=a4
    a4=close
    endif
     
    return changement coloured by t[1] as "cassure"
    

    Par contre certains changements sont  decalés  or j’ai juste rajouté une quatrieme variable par rapport au code original

    merci de votre aide

    lowbat thanked this post
Viewing 1 post (of 1 total)
  • You must be logged in to reply to this topic.

Three line break / Four line break


ProBuilder : Indicateurs & Outils Personnalisés

New Reply
Author
author-avatar
Nico @nico Participant
Summary

This topic contains 1 voice and has 0 replies.

Topic Details
Forum: ProBuilder : Indicateurs & Outils Personnalisés
Language: French
Started: 08/07/2017
Status: Active
Attachments: No files
Logo Logo
Loading...