Problème coloration COLOBETWEEN

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #224832 quote
    PRC_2021
    Participant
    Average

    Bonjour,

    Je cherche à colorier une partie des bande de bollinger => Ok

    Mais le problème c’est que cela continue ensuite à plat.

    Savez vous d’où provient le problème svp ?

    if (condition1) then
    COLORBETWEEN(BBinf,BBinfbis,0,255,0,50)
    elsif (condition2) then
    COLORBETWEEN(BBsup,BBsupbis,255,0,0,50)
    endif

    Merci

    #224835 quote
    PRC_2021
    Participant
    Average

    Avec la pj 😉

    coloration.pdf
    #224838 quote
    JC_Bywan
    Moderator
    Master

    Bjr,

    if (condition1) then
    alpha1=50
    alpha2=0
    elsif (condition2) then
    alpha1=0
    alpha2=50
    endif
    
    COLORBETWEEN(BBinf,BBinfbis,0,255,0,alpha1)
    COLORBETWEEN(BBsup,BBsupbis,255,0,0,alpha2)
    PRC_2021 thanked this post
    #224839 quote
    LucasBest
    Participant
    Average

    C’est un des problèmes de cette instruction (à ma connaissance).

    Quand il commence, il ne sait pas s’arrêter… 🙂

    Il faut donc contourner le problème :

    if (condition1) then
    highlight1 = 50
    else
    highlight1 = 0
    endif
    
    If condition2 then
    highlight2 = 50
    else
    highlight2 = 0
    endif
    
    COLORBETWEEN(BBinf,BBinfbis,0,255,0,highlight1)
    COLORBETWEEN(BBsup,BBsupbis,255,0,0,highlight2)
    
    PRC_2021 thanked this post
    #224840 quote
    LucasBest
    Participant
    Average

    Il semblerait que JC_Bywan Kenobi le Jedi a dégainé plus vite que moi… 🙂

    #224842 quote
    PRC_2021
    Participant
    Average

    Super merci beaucoup. Je vais tester cela 😊

    #224863 quote
    JC_Bywan
    Moderator
    Master

    Il semblerait que JC_Bywan Kenobi le Jedi a dégainé plus vite que moi… 🙂

    Tant qu’on est tous les 2 plus rapides que Greedo…

    Désolé PRC_2021 de dévier un peu du sujet, mais LucasBest est-ce que c’était toi qui avait fait un message à propos de matrices à inverser il y a quelques mois? Je voulais y jeter un oeil quand j’avais des sujets en retard sur juillet-septembre, mais je l’ai pas mis en marque-page…

    #224894 quote
    LaMaille
    Participant
    Junior

    Oui, c’était pour un indicateur de régression polynomial… je pense avoir trouvé la solution, mais je ne l’ai pas codé jusqu’au bout.

    Pine Scipt conversion – Polynomial Regression Extrapolation

    ps : C’est LucasBest 🙂

    #224978 quote
    JC_Bywan
    Moderator
    Master

    Ah oui merci, c’était bien celui-là, je voulais tenter quelque chose, je regarde si c’est faisable dès que je peux, idéalement avant Noël pour ne pas laisser trainer un truc d’une année sur l’autre et clôturer ma phase de rattrapage des sujets de cette période.

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

Problème coloration COLOBETWEEN


ProBuilder : Indicateurs & Outils Personnalisés

New Reply
Author
author-avatar
PRC_2021 @manu35250 Participant
Summary

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

Topic Details
Forum: ProBuilder : Indicateurs & Outils Personnalisés
Language: French
Started: 12/04/2023
Status: Active
Attachments: 1 files
Logo Logo
Loading...