【问题标题】:How to use the Alertcondition feature right, I am doing something wrong?如何正确使用 Alertcondition 功能,我做错了什么?
【发布时间】:2020-10-01 14:01:48
【问题描述】:

我正在尝试在 pinescript 中使用 Alertfunction。我是编码的菜鸟,想修改现有的东西。

//警报

plotshape(longCondition, title = "Buy Signal", text ="LONG", textcolor = white, style=shape.labelup, size = size.normal, location=location.belowbar, color = green, transp = 0)
plotshape(shortCondition, title = "Sell Signal", text ="SHORT", textcolor = white, style=shape.labeldown, size = size.normal, location=location.abovebar, color = red, transp = 0)

alertcondition(longCondition,title="Long",message="Long @ ..")
alertcondition(shortCondition,title="Short",message="Short @ .. ")

我希望当策略具有买入警报时可选择多头警报,反之亦然。

如果有人可以帮助我解决我遗漏或做错的事情,我将不胜感激。

策略是可编译的,但当我想使用交易视图创建警报时没有任何选择。

谢谢!

【问题讨论】:

    标签: pine-script


    【解决方案1】:

    您无法使用策略以这种方式创建警报。请参阅 here 了解警报如何用于策略。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2017-09-29
      • 2013-10-21
      • 2023-01-26
      • 1970-01-01
      • 2019-08-25
      • 2013-09-07
      • 2017-03-01
      相关资源
      最近更新 更多