当我的条件被触发时,我如何在价格水平上画一条水平线?(版本#4)
plotshape(crossUp_red ? rvi : na, title="Up Arrow", style=shape.arrowup, location=location.abovebar, color=#109c3f, size=size.small, text="crossUp_red") // plots arrow
然而,我在绘制触发“crossUp_red”的价格线时遇到了问题。
trigger_price = valuewhen(crossUp_red, close, 0)
plot(trigger_price, title="line_crossUp_red", color=color.green, linewidth=2, transp=0)
绘制直线/所有直线,但聚集在图表底部。
trigger_price = valuewhen(crossUp_red, close, 0)
hline(trigger_price, title="Trigger Price", color=color.red, linestyle=hline.style_dotted)
错误:无法使用“price”=series[foat]调用“hline”。参数的类型应为:input float
非常感谢。