下面的脚本将触发策略的开盘部分,收盘后的柱。如何更改变量“关闭”,以便在 SMA 14 和 28 交叉的确切点而不是之后的柱线处测试策略?或者那不可能
longCondition = crossover(sma(close, 14), sma(close, 28))
if (longCondition)
strategy.entry("My Long Entry Id", strategy.long)
shortCondition = crossunder(sma(close, 14), sma(close, 28))
if (shortCondition)
strategy.entry("My Short Entry Id", strategy.short)