Pine script 在tradingview中关闭酒吧时的入口价格变化
我使用收盘价作为进场价,但当酒吧关闭时,进场价将获得收盘价。以下代码中的输入价格正在更改。有人能拦住我吗Pine script 在tradingview中关闭酒吧时的入口价格变化,pine-script,Pine Script,我使用收盘价作为进场价,但当酒吧关闭时,进场价将获得收盘价。以下代码中的输入价格正在更改。有人能拦住我吗 if(bought_long == false and barssince(crossover(ema9, ema20)) == 0 and low[2] < open and low[2] < low[1] and ema9 > ema20) stop_loss_long := low[2] entry_price_long := c
if(bought_long == false and barssince(crossover(ema9, ema20)) == 0 and low[2] < open and low[2] <
low[1] and ema9 > ema20)
stop_loss_long := low[2]
entry_price_long := close
if(bunded_long==false和barssince(crossover(ema9,ema20))==0和low[2]ema20)
停止损失长:=低[2]
分录价格长:=结束
您可以根据您的条件使用此选项在条形图上获取打开的价格:
cond bought_long == false and barssince(crossover(ema9, ema20)) == 0 and low[2] < open and low[2] < low[1] and ema9 > ema20
if cond[1]
stop_loss_long := low[3]
entry_price_long := open
cond-bunded\u-long==false和barssince(交叉(ema9,ema20))==0和低[2]ema20
如果条件[1]
止损长:=低[3]
输入\价格\长度:=打开