KNOWLEDGEBASE - ARTICLE #1299

What is the Median Absolute Deviation (MAD) ?

MAD of a set of values

The Median Absolute Deviation (MAD) is a simple way to quantify variation. Half the values are closer to the median than the MAD, and half are further away.  GraphPad Prism does not (yet) compute the MAD.

The best way to understand the MAD is to understand how it is calculated. First, compute the median of all the values. The median is the 50th percentile. Then calculate how far each value is from the median of all values. Regardless of whether the value is greater or less than the median, express the distance between it and the median as a positive value (in math terminology, take the absolute value of the difference between the value and the median). Now find the median of that set of differences. The result is the Median Absolute Deviation, abbreviated MAD.

Note one point of confusion. There are two distinct computations of the median. First one computes the median of the actual data. Then one computes the median of the distances of the values from that median.

You can’t compare the MAD directly to the interquartile range. Half of the values are within one MAD of the median, in either direction. So if you want to create a range that contains half the values, you’d need to go one MAD in each direction from the median. So you’d expect twice the MAD to approximately equal the interquartile range.

The MAD is resistant to outliers. The presence of outliers does not change the value of the MAD. In this respect, it is similar to the interquartile range. In contrast, the SD is very sensitive to the presence of outliers.

MAD of residuals in regression

When assessing residuals from linear or nonlinear regression, the MAD is computed a bit differently. Each residual is the distance of a point from the best-fit line or curve. With ordianry regressions, only the vertical distance matters. Points that are above the line or curve have positive residuals. Points below the line or curve have negative residuals.  Regardless of whether the residual is positive or negative, express the distance between it and the best-fit line or curve as a positive value (in math terminology, take the absolute value of the residual). Now find the median of that set of values. The result is the Median Absolute Deviation, abbreviated MAD.

Explore the Knowledgebase

Analyze, graph and present your scientific work easily with GraphPad Prism. No coding required.