=MEDIAN(number1, [number2], ...)
=MEDIAN(A2:A6)
The MEDIAN function returns the median of any given range of numbers. For example, this returns the median of the five numbers in the range A2:A6. The median number is the one in the very middle of the range.
=MEDIAN(A2:A7)
If the range contains an even number of elements, the MEDIAN function will return the number halfway between the two middle elements. For example, this returns the median of the six numbers in the range A2:A7, which is the midway point between the third and fourth numbers.
The MEDIAN function is used to calculate the median value of a given set of numbers. The median is the middle number in a group of numbers.