The **median **is another measure of the central tendency of your sample. The median is the number “in the middle” of the dataset, the middle value of a series of values sorted from the smallest to the largest.

Providing that your dataset contain an **odd number n** of entries, the median is the

**value of the ((**in the dataset. If the dataset contains an

*n*+1)/2)^{th}entry**even number**, then the median is the

*n*of entries**average of the values of the (**.

*n*/2)^{th}and ((*n*/2)+1)^{th}entriesIn R, the function that calculates the median is called `median()`

:

my.dataset <- c(1,2,3,4,5,6,7,8,9,10) median(my.dataset)