Long term strategy for managing a Crypto investment with Swing Trades of more than 1 day. The strategy buys with a stop order at the Swing High price (green line) and sells with a stop order at the Swing Low price (red line). The direction of the strategy can be adjusted in the Inputs panel.
Can someone well versed in Pine tell me why the position gets closed (instead of reversed) with the strategy.exit() function when an opposite signal is true?