“Display” function in indicator

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #189860 quote
    slevinkelevra
    Participant
    New

    Hi there,

    I wonder if there is any function to make such an hypothetical code:

    If A=1 and B=2 Then
    
    "Display" Indicator X
    
    Else
    
    "Do not Display" Indicator X
    
    Endif
    
    Return A, B, Indicator X // the ideia is to only show the value of this indicator X when conditions is showned otherwise do not show it. 
                             //In other words I was trying to get the value of indicator X only at signal candles

    In the example, I illustrate the point where I only would like to check the Indicator X value.

     

    Thank you so much and wish you a wonderful weekend

    example1.jpg example1.jpg
    #189901 quote
    robertogozzi
    Moderator
    Master

    You can simply tell ProBuilder to plot using full transparency (the optional fourth display parameters set to 0) so it is made invisible:

    If A=1 and B=2 Then
       t = 255                      //make it fully visible
    Else
       t = 0                        //make in invisible
    Endif
    Return A, B, Indicator X coloured(0,0,0,t) // the ideia is to only show the value of this indicator X when conditions is showned otherwise do not show it. 
                             //In other words I was trying to get the value of indicator X only at signal candles
    denmar thanked this post
Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.

“Display” function in indicator


ProBuilder: Indicators & Custom Tools

New Reply
Author
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by robertogozzi
4 years ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 03/12/2022
Status: Active
Attachments: 1 files
Logo Logo
Loading...