Double MAD vs the Rest

Double MAD vs the Rest
Adam Cassar

Co-Founder

2 min read

Limitations of Double MAD and Comparison with Z-Score

As powerful as Double MAD is in anomaly detection, it's important to acknowledge its limitations. One key limitation is its inability to account for the shape of seasonal data. Time series data often exhibit cyclical patterns based on the time of day, week, or year. For instance, web traffic to an e-commerce site might spike during holidays and dip on off-peak days.

While Double MAD can capture shifts in the median of these data, it does not consider the shape or pattern of the data within these cycles. As such, it might fail to detect anomalies that occur within a specific season, or it might flag normal seasonal variations as anomalies.

Another potential limitation of Double MAD is that it doesn't account for trends over time. In other words, if your time series data exhibits a consistent increase or decrease over time, Double MAD might misinterpret this trend as a series of anomalies.

Double MAD vs. Z-Score

When discussing anomaly detection, it's worth comparing Double MAD to the more traditional Z-score method. A Z-score measures how many standard deviations a data point is from the mean. It assumes that the data follows a Gaussian (or normal) distribution, which often doesn't hold true for real-world data.

Double MAD, on the other hand, is a non-parametric method that doesn't make any assumptions about the distribution of data. This makes it more robust to outliers and skewed distributions.

However, Z-score holds an advantage when it comes to data that follows a Gaussian distribution or when the data size is large enough for the Central Limit Theorem to take effect. It also accounts for the mean and standard deviation, giving it an edge in datasets where these measures are informative.

In contrast, Double MAD is more robust for datasets with outliers or skewed distributions, as it uses the median and absolute deviations from the median, which are less sensitive to extreme values.

In summary, while both Double MAD and Z-score have their strengths, the choice between them should be guided by the nature of your data. Understanding these nuances can help you make an informed decision and apply the most effective method for your specific use case.

Enterprise-Grade Security and Performance

Peakhour offers enterprise-grade security to shield your applications from DDoS attacks, bots, and online fraud, while our global CDN ensures optimal performance.

Contact Us

Related Content

When Bots Break Bad

When Bots Break Bad

Even 'good' bots can end up abusing your site and impacting performance, learn why and how to stop it.

Advanced Anomaly Detection

Advanced Anomaly Detection

Deep dive into Robust Random Cut Forest (RRCF) implementation for real-time anomaly detection in Application Security Platforms. Learn how advanced machine learning algorithms enhance threat detection and automated response capabilities.

Double MAD?

Double MAD?

This article explores the use of Double Median Absolute Deviation (Double MAD) for anomaly detection in time series data, particularly in skewed or non-symmetric distributions.

Scaling anomaly detection with RRCF

Scaling anomaly detection with RRCF

Discusses strategies for scaling the Robust Random Cut Forest (RRCF) algorithm for large-scale anomaly detection, including using summary statistics, buffering input, and parallelisation.

© PEAKHOUR.IO PTY LTD 2025   ABN 76 619 930 826    All rights reserved.