у меня есть код:
strategy(title="StackOverflowExample", overlay=true, slippage=200, commission_type=strategy.commission.percent, commission_value=0.2)
long=crossover(sma(close, 10), sma(close, 20))
close_condition=crossunder(sma(close, 10), sma(close, 20))
stl=strategy.position_avg_price *0.97
strategy.entry("long", true, 1, when = long)
strategy.close("long" , when = close_condition)
strategy.exit("exit", "long", stop=stl, trail_price=strategy.position_avg_price*1.04 ,trail_offset=close*0.03/syminfo.mintick)
Как перевернуть позицию в обоих случаях? (strategy.close (), strategy.exit ())