Pine script Pine脚本中screener的自定义函数
我正在尝试将现有的开源screener转换为我自己的脚本 我的脚本中有这行代码,我想为它编写一个函数,可以扫描市场寻找可能的机会Pine script Pine脚本中screener的自定义函数,pine-script,Pine Script,我正在尝试将现有的开源screener转换为我自己的脚本 我的脚本中有这行代码,我想为它编写一个函数,可以扫描市场寻找可能的机会 color = show_a ? d_tc > d_bc and d_poi < p_poi ? color.white : d_tc < d_bc and d_poi > p_poi ? color.white : d_poi > d_bc ? color.green : d_poi < d_bc ? color.red : co
color =
show_a ?
d_tc > d_bc and d_poi < p_poi ? color.white :
d_tc < d_bc and d_poi > p_poi ? color.white :
d_poi > d_bc ? color.green :
d_poi < d_bc ? color.red :
color.silver :
na
plot(d_poi, color = c_colo, title = "points")
golong=c_colo ==color.green
goshort=c_colo==color.red
alertcondition(golong, "Buy", " Buy Signal at {{exchange}}:{{ticker}}, Price = {{close}} at
{{timenow}}")
alertcondition(goshort, "Sell", " Sell Signal at {{exchange}}:{{ticker}}, Price = {{close}} at
{{timenow}}")
颜色=
秀给你看?
d_tc>d_bc和d_poip_poi?颜色。白色:
d_poi>d_bc?颜色。绿色:
d_poi
现在,我使用的自定义筛选程序来自Quant Nomad的链接
我希望当条件满足时,扫描仪将显示所有机会
color =
show_a ?
d_tc > d_bc and d_poi < p_poi ? color.white :
d_tc < d_bc and d_poi > p_poi ? color.white :
d_poi > d_bc ? color.green :
d_poi < d_bc ? color.red :
color.silver :
na
plot(d_poi, color = c_colo, title = "points")
golong=c_colo ==color.green
goshort=c_colo==color.red
alertcondition(golong, "Buy", " Buy Signal at {{exchange}}:{{ticker}}, Price = {{close}} at
{{timenow}}")
alertcondition(goshort, "Sell", " Sell Signal at {{exchange}}:{{ticker}}, Price = {{close}} at
{{timenow}}")
请帮忙