I am back testing historical data, want to know how can I get the last trade type (Long or Short) that completed after strategy exit trade due to either reversing of crossover or SetStoploss() or SetProfitTarget().
I have Partial success in getting that in case of crossover reversing cause it will be opposite of new generated signal, but unable to get when position get flat due to stop loss or profit target.
Comment