Print value in right expansion area


Category:
0
0

Is it possible to display values in the right expansion area? I’m attaching a screenshot of what I want.

Attachments:
Marked as spam
Posted by (Questions: 4, Answers: 2)
Asked on May 1, 2020 3:08 am
328 views
0
Private answer

No, this is not at all possible on Thinkorswim. Best you can do are chart bubbles and you have very little control over their placement. You have to tie each chart bubble to two reference points. One is time based and the other is numeric.

Let's say you wanted to plot a chart bubble one bar to the right of the last bar on the chart. We can place this chart bubble at the low of the last bar on the chart:

def lastBar = IsNaN(close[-1]) and !IsNaN(close);
AddChartBubble(lastBar[1], low[1], "Test", Color.WHITE, yes);

That example shows you how you can do this. If you are writing your own code you should be able to work out ways to move the chart bubble vertically and horizontally in reference to the last bar on the chart.

Marked as spam
Posted by (Questions: 37, Answers: 4087)
Answered on May 1, 2020 8:05 am
0
That's very helpful. I didn't realize we can access bars beyond the current bar. I'm trying to get the Highest and Lowest of the visible ticks so I can Scale the location of the Bubbles. I don't see a way yet. I guess I would need to know the number of visible ticks so I can pass it to the Highest() and Lowest() function. Cheers.
( at May 1, 2020 2:10 pm)
0
You might also want to try using HighestAll() and LowestAll(). Those two functions will capture data that is not in the immediate view of the chart (meaning the section to the left that you need to use the scroll bar to view).
( at May 1, 2020 4:28 pm)