By adjusting the time window within which the filter computes its mean and deviation, you can provide some protection against false positive outliers. The high correlation between price values over subsequent time windows would provide you with some buffering. For example, if S&P dips an anomalous amount in one day, it's unlikely to shoot back up after one timepoint. If you are finding that shocks are being labeled as outliers, you may want to adjust your sampling intervals to be more precise (e.g., from dailies to hourlies). More likely the downward trend continues, as we can see from 2022 Q1 and Q2 :)

Jozsef Meszaros
Jozsef Meszaros

No responses yet