The primary algorithm uses median absolute deviation to replace standard deviation, to make it more robust against anomaly points.
But in this code, pandas.mad() is used. However, pandas.mad() is mean absolute deviation, not median absolute deviation. Both can work, but median absolute deviation is better, in my opinion.
The primary algorithm uses median absolute deviation to replace standard deviation, to make it more robust against anomaly points.
But in this code, pandas.mad() is used. However, pandas.mad() is mean absolute deviation, not median absolute deviation. Both can work, but median absolute deviation is better, in my opinion.