Hide Chart Bubbles Alert HI LOW V2


Category:
0
0

I downloaded the second version of the Alert Hi Low v2.  I noticed that when I uncheck the box of show bubble.  I still see the bubble.  I’m trying to uncheck the Low.  Can you let me know how to update the file to no longer view the bubble? Thanks.

Marked as spam
Posted by (Questions: 1, Answers: 0)
Asked on November 17, 2017 9:26 pm
1092 views
0

I updated the title of your post because it was a bit to vague. I wanted to make sure visitors could easily find and understand the context from the question title.

( at November 18, 2017 9:14 am)
0
Private answer

First, let’s make everyone visiting this post knows where to get the code by linking the video you referenced in your question: https://www.hahn-tech.com/thinkorswim-alert-high-low-version-two/

Ok the solution here requires two lines of code to be added and two lines of code to be modified. Once complete, the chart bubbles for the highs and the lows can each be independently turned on or off. (on by default).

First step is to add these two new lines (be sure to add them near the top, along with the rest of the inputs):

input showBubblesHigh = yes;
input showBubblesLow = yes;

Those two lines will add two new user inputs which can be adjusted in the study settings.

Now, locate the following lines (towards the bottom of the code)

AddChartBubble(DailyHigh > DailyHigh[1] and hideChartBubbles and okToPlot, DailyHigh, "Hi", color.GREEN, yes);
AddChartBubble(DailyLow < DailyLow[1] and hideChartBubbles and okToPlot, DailyLow, "Lo", color.RED, no);

All we need to do is add those two new inputs, one for each set of chart bubbles, as a true/false condition. Here is the modified version of those two lines of code:
AddChartBubble(showBubblesHigh and DailyHigh > DailyHigh[1] and hideChartBubbles and okToPlot, DailyHigh, "Hi", color.GREEN, yes);
AddChartBubble(showBubblesLow and DailyLow < DailyLow[1] and hideChartBubbles and okToPlot, DailyLow, "Lo", color.RED, no);

That’s all there is to it.

Marked as spam
Posted by (Questions: 37, Answers: 4118)
Answered on November 18, 2017 9:08 am