This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.1)

Median

Median[list]
gives the median of the elements in list.
Median[dist]
gives the median of the symbolic distribution dist.
  • Median[list] gives the center element in the sorted version of list, or the average of the two center elements if list is of even length.
Find the middle value in the list:
Average the two middle values:
Median of a symbolic distribution:
Find the middle value in the list:
In[1]:=
Click for copyable input
Out[1]=
 
Average the two middle values:
In[1]:=
Click for copyable input
Out[1]=
 
Median of a symbolic distribution:
In[1]:=
Click for copyable input
Out[1]=
Median works with any real numeric quantities:
Median finds medians of elements in each column:
Obtain results at any precision:
Compute results for a large vector or matrix:
Obtain a robust estimate of location when outliers are present:
Extreme values have a large influence on the Mean:
Medians of random reals approach a Gaussian distribution:
Theoretical curve:
Median is equivalent to a parametrized Quantile:
For nearly symmetric samples, Median and Mean are nearly the same:
The Median of absolute deviations from the Median is MedianDeviation:
MovingMedian is a sequence of medians:
Median requires numeric values:
New in 5 | Last modified in 7