为什么这个指标/代码现在不会打印在图表上。它已经工作了2年多了,现在不起作用了。
study(title="5AM 30M Open Range", shorttitle="_openrange", overlay=true)
period_str = "0000-1000"
period_series = time(period, period_str)
is_newbar(res) => change(time(res, period_str)) != 0
adopt(r, s) => security(tickerid, r, s)
high_range = valuewhen(is_newbar('D'),high,0)
low_range = valuewhen(is_newbar('D'),low,0)
up30 = plot(period_series > 0 ? adopt('30', high_range) : na, color = olive, style=linebr, linewidth=1)
down30 = plot(period_series > 0 ? adopt('30', low_range) : na, color = olive, style=linebr, linewidth=1)
fill(up30, down30, color = olive)