### [A, SfS] Chapter 1: Sampling, Descriptive Statistics, Intr: 1.7: The Median

### The Median

The Median

In this section you will learn:

- What the median is and how to calculate it.

#\text{}#

In the previous section, we discussed that one of the downsides of using the *mean *as a measure of center is that it is strongly influenced by the presence of outliers in the data set. We mentioned that one possible way to mitigate this problem is to calculate the #p\%# *trimmed mean *instead.

This section introduces a second measure of center that is resistant to the influence of extreme values, the *median.*

Median

The **median** is the midpoint of a distribution. It is the score that divides the distribution into two equal halves, meaning exactly #50\%# of the scores in a distribution are equal to or less than the median.

Median Calculation

To calculate the *median*, first order the scores in either ascending or descending order.

Next, determine whether there are an odd or even number of scores in the distribution.

- If the distribution consists of an
**odd**number of scores, the median is the*middle score*in the list of ordered scores. This score will be located at the #(\cfrac{n+1}{2})#th position of the list. - If the distribution consists of an
**even**number of scores, the median is the value halfway between the*middle two**scores*. These middle scores are located at the #(\cfrac{n}{2})#th and the #(\cfrac{n}{2} + 1)#th position of the list.

#\text{Median}=7#

To determine the median of a sample, first order the scores in either ascending or descending order:

\[2,\,\,\,2,\,\,\,5,\,\,\,7,\,\,\,7,\,\,\,10,\,\,\,10\]

The sample is made up out of #n=7# scores.

Since there are an odd number of scores in the sample, the median is equal to the middle score of the ordered list.

For a sample of #7# scores, the middle score is located at the #(\frac{n+1}{2})=\frac{7+1}{2}=4#th position.\[\text{Median} = x_{4} = 7\]

#\text{}#

Using R

**Median**

If you have measurements on a quantitative variable stored in an #\mathrm{R}# vector, finding the median requires much less effort than following the steps given above.

Suppose the name of the vector is #\mathtt{Length}#. To find the median, just use:

`> median(Length)`

**Pass Your Math**independent of your university. See pricing and more.

Or visit omptest.org if jou are taking an OMPT exam.