I am trying to modify a pine script indicator on TradingView so that it displays the value of the indicator/plot next to the title of the indicator on the main chart. However, I don't want to actually plot anything because it messes up the scale of the chart. I also don't want it to show up in a separate window above or below the chart. Is this possible with Pine Script?
I attempted passing in display=display.none to the "plot" function, but that removed both the value label and the line. Here is the code (image example does not have "display" parameter):
//@version=4
study(title="ADR %", overlay=true)
length = input(20, title="length")
dhigh = security(syminfo.tickerid, 'D', high)
dlow = security(syminfo.tickerid, 'D', low)
adr = 100 * (sma(dhigh/dlow, length) - 1)
plot(adr, title="ADR %", display=display.none)
Thank you!!
