我有一个非常简单的测试策略,其中入场按预期进行,买入侧的退出也按预期进行,但是卖出侧的strategy.exit会在建仓后立即平仓,因此不会占用获利并停止考虑。有人知道解决方法吗?
//Sell
strategy.entry("Fade Tick Short", strategy.short, 1, when = tickHigh > 1000 )
strategy.exit("exit1", "Fade Tick Short", profit=16, stop=8) // This line does not work
//Buy
strategy.entry("Fade Tick Long", true, 1, when = tickLow < -1000 )
strategy.exit("exit2", "Fade Tick Long", profit=16, stop=8)