Join our Newsletter — 33% off our NHI Course

Median Absolute Deviation

Median absolute deviation, or MAD, is a robust measure of spread that resists outliers better than a standard deviation based on the mean. In detection pipelines, it helps keep a few extreme events from defining normal, which is useful when telemetry contains noise or early compromise signals.

Expanded Definition

Median absolute deviation, or MAD, is a robust dispersion metric that measures how far observations typically sit from the median, rather than from the mean. That makes it especially useful when telemetry is skewed, sparse, or punctuated by extreme values that would distort a standard deviation calculation. In security analytics, MAD is often used to set adaptive baselines for unusual authentication activity, process execution counts, API calls, or sensor readings where a few spikes should not reset the definition of normal. As a statistical concept, it is broader than any single toolchain, but its security value appears when teams need stable thresholds that do not collapse under noisy data. NIST’s control catalog at NIST SP 800-53 Rev 5 Security and Privacy Controls is often used alongside anomaly-detection programs that rely on resilient baselining, even though the catalog does not define MAD itself. The most common misapplication is treating MAD as a direct replacement for standard deviation in every dataset, which occurs when teams ignore whether the distribution is sufficiently symmetric or whether zero-inflated counts need a different thresholding approach.

Examples and Use Cases

Implementing MAD rigorously often introduces a tradeoff between resilience to outliers and sensitivity to gradual drift, requiring organisations to weigh stable detection thresholds against the risk of missing slow-moving change.

  • Security operations teams use MAD to flag login volumes that exceed a user’s normal range without letting a single incident define the baseline.
  • Fraud and account abuse monitoring apply MAD to payment or session metrics when rare spikes are expected and should not dominate alerting logic.
  • Threat hunters use MAD to identify unusual host activity, such as command frequency or outbound connection counts, in noisy endpoint telemetry.
  • Cloud security teams can combine MAD-based thresholds with guidance from NIST SP 800-53 Rev 5 Security and Privacy Controls when evaluating whether alerting and monitoring controls are consistently applied.
  • Identity teams use MAD to separate routine sign-in patterns from unusual access bursts, especially where service accounts, automated jobs, or shared administrative workflows create non-Gaussian noise.

Across these use cases, the point is not to eliminate false positives entirely, but to prevent one-off extremes from defining the baseline for everyone else. That makes MAD especially valuable in environments where telemetry includes early compromise indicators mixed with legitimate operational spikes.

Why It Matters for Security Teams

Security teams rely on MAD when they need baselines that remain credible under adversarial noise, seasonal change, or incomplete data. If analysts anchor detection logic to the mean and standard deviation alone, a small number of extreme values can widen thresholds so much that real anomalies disappear into the background. MAD is therefore a practical guardrail for alert quality, especially in SOC workflows, detection engineering, and identity analytics where event volumes are uneven. It also supports governance because stable thresholding helps teams explain why a rule fired and whether it reflects a meaningful deviation or ordinary operational variance. In identity and NHI-adjacent monitoring, MAD can help distinguish routine automation from suspicious credential use or agent behaviour, but only if the underlying metric is selected carefully and reviewed over time. For teams following control-oriented monitoring practices, the relevant concern is not the statistic itself, but whether the detection process is repeatable, justified, and tuned to the business context. Organisations typically encounter the limits of their baselines only after a noisy incident floods the queue, at which point MAD becomes operationally unavoidable to address.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Non-Human Identity Top 10 address the attack and risk surface, while NIST CSF 2.0, NIST SP 800-53 Rev 5, NIST SP 800-63 and NIST AI RMF set the governance and control requirements practitioners need to meet.

Framework Control / Reference Relevance
NIST CSF 2.0 DE.AE-1 NIST CSF addresses anomalous activity detection, where MAD supports stable baselines.
NIST SP 800-53 Rev 5 AU-6 AU-6 covers audit record review and analysis, which often relies on anomaly thresholds.
NIST SP 800-63 Digital identity assurance contexts use behavioral signals where robust spread metrics matter.
OWASP Non-Human Identity Top 10 NHI monitoring often needs robust metrics to spot abnormal secret or agent behavior.
NIST AI RMF AI RMF supports measurement and monitoring practices that benefit from robust statistics.

Use MAD-based baselines carefully when evaluating unusual authentication patterns.