Description
Automatically find the sample median and the unscaled median of its absolute deviations, without a normal-consistency correction.
Median absolute deviation takes the median of distances from the sample median. It measures spread in the original data units and differs from the mean of those distances. Scaling a MAD to estimate a normal-distribution standard deviation is an additional convention.
Automatically find the sample median and the unscaled median of its absolute deviations, without a normal-consistency correction.
When to use this tool
Use this tool to calculate median absolute deviation under the units, normalization, and boundary conventions below.
How to use the tool and how it works
- Supply values in the field shapes below.
- Run the calculation. Correct format, shape, range, or undefined-statistic errors before interpreting a result.
- Read count, deviation, median. Use the conventions below.
Find the sample median, calculate every absolute deviation from that median, then take the median of those deviations. For an even-sized median calculation use the middle pair under the implementation’s stable arithmetic.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| values | Values | Required. Array of Finite number.; minimum items 1; maximum items 512. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| count | Requested count; the mechanics explain whether one draw expands into several returned records. | Required. Safe integer; minimum 1; maximum 512. |
| deviation | The specified unscaled mean or median absolute deviation, in the same units as values. | Required. Finite number; minimum 0. |
| median | Sample median in the same units as values. | Required. Finite number. |
{
"input": {
"values": [
2,
3,
3,
5,
100
]
},
"output": {
"count": 5,
"deviation": 1,
"median": 3
}
} Limitations and assumptions
- This is unscaled median absolute deviation in the original measurement units. No normal-consistency multiplier is applied; it differs from the mean of absolute deviations and is not an automatic outlier decision.
- The field tables state structural bounds; cross-field constraints and bounded search or output budgets also apply. Unknown keys are rejected where the object contract disallows them. Input errors are distinct from null fields and deliberate invalid controls in a successful output.
Alternative or Complementary methods
Choose the statistic according to the question and data conventions. Inspect the supplied series or matrix and the stated assumptions before comparing outputs from implementations with different defaults.
References
Similar or alternative tools
- mean absolute deviation from median
Automatically find the sample median and average its absolute deviations, without confusing this mean aggregation with the median absolute deviation statistic.
- standard deviation
Calculate the population standard deviation of a finite dataset.