Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Can't get hor lines 20&80 on indicator

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Can't get hor lines 20&80 on indicator

    Hello,
    i can't get the horizontal lines of the 20 and 80 on the indicator as you can see on the attached picture. Above the MFI with the right ones, below the problem on the BolligerPercB.

    Code:
    protected override void Initialize()
            {
                Add(new Plot(Color.DarkBlue, "BpB"));
                Add(new Line(Color.Red, 20, "Lower"));
                Add(new Line(Color.Green, 80, "Upper"));
            }
    Attached Files

    #2
    I would try 0.2 and 0.8 for the Bollinger % one, looks like it's not scaling to 0 - 100 range...

    Comment


      #3
      Thanks Bertrand,
      scaling 0.2 and 0.8 works.
      But how can i scaling 0-100 ??

      Comment


        #4
        You would need to change the indicator outputted value for the plot for example by multiplying it with a custom factor...

        Comment


          #5
          If you take a look at the RSI source for ex. , there is nothing other to do and the hor-line values are set to 20 & 80.

          Comment


            #6
            Correct, because the RSI per se would be range bound from 0-100 by it's normal calculations.

            Comment


              #7
              Mine would be range bound 0-100 also.

              and others on the guide.

              Comment


                #8
                Sorry I don't follow your last reply - the Bollinger % B custom indicator would not scale to 0-100 per default, hence you would either need to

                a) work with adjusted overbought / oversold levels i.e. 0.2 and 0.8

                b) change the output value from the custom indicator to fit your scaling needs

                Comment


                  #9
                  Thanks Bertrand,
                  i had to multiply the %B by 100. ( see your previous post )
                  The scale follows the indicator (%B) automatically.

                  Comment


                    #10
                    Glad to hear that mate41.

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                    0 responses
                    579 views
                    0 likes
                    Last Post Geovanny Suaza  
                    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                    0 responses
                    334 views
                    1 like
                    Last Post Geovanny Suaza  
                    Started by Mindset, 02-09-2026, 11:44 AM
                    0 responses
                    101 views
                    0 likes
                    Last Post Mindset
                    by Mindset
                     
                    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                    0 responses
                    554 views
                    1 like
                    Last Post Geovanny Suaza  
                    Started by RFrosty, 01-28-2026, 06:49 PM
                    0 responses
                    551 views
                    1 like
                    Last Post RFrosty
                    by RFrosty
                     
                    Working...
                    X