Backtesting Scripts give wrong Results in PI

Plotted is Backtesting chart for simplest script run over 3 days in 5 min interval in latest PI release:

Buy : Close < PSAR(CLOSE,0.02, 0.2)

Exit : Close < PSAR(CLOSE,0.02, 0.2)

There are wrong trades ! Please tell how do we work with PI in such scenario.


DA2243

looks buy and exit buy codes are same as per above please verify it once again , i check the PSAR on my pi it is working fine for me.

Algo…For me too Psar is not working properly I tried many times in the past…

Dear AlgoGeek. Buy and sell codes are not the same. As shown in chart, Buy has CLOSE > PSAR, and Sell has CLOSE < PSAR. Also the spikes shown at Crossover in Red and Green colour are not coincident.
Please try the following script :
Buy: CROSSOVER (CLOSE, PSAR(CLOSE,0.02,0.2))
Exit: CROSSOVER (PSAR(CLOSE,0.02,0.2), CLOSE)
Please try it on any script like Silver in MCX for 3 days at interval of 5 min candle.
Thank you.