Advertisement

Median calculator

Paste the observations in any order. The calculator sorts a copy of the list and finds its central value or central pair.

Calculator

Use commas, spaces or new lines between numbers. Use the same unit for every observation.

Median
3.000000
Observation count
5.000000
Lower middle observation
3.000000
Upper middle observation
3.000000
Ordered observations
PositionValue
1.0000001.000000
2.0000002.000000
3.0000003.000000
4.0000004.000000
5.0000005.000000

Advertisement

How this calculator works

Ordering determines the centre independently of the original entry positions. An odd-sized list has one central observation. An even-sized list has two, and their arithmetic average is the conventional numeric median. Ties are retained as separate observations. The median keeps the original measurement unit and can lie between observations when the list has even length.

Formula

For ordered x: median = x((n + 1)/2) when n is odd; median = (x(n/2) + x(n/2 + 1))/2 when n is even.

Worked example

The values 8, 2, 4, 6 sort to 2, 4, 6, 8. The middle pair is 4 and 6, so the median is 5.

Advertisement

Frequently asked questions

Does the median have to appear in the list?

No. The average of an even-sized central pair may be a new value.

Should I remove duplicate values?

No. Duplicates represent repeated observations and affect the centre.

What happens with one observation?

That observation is the median and both displayed central values. An empty list has no median.

Sources

Advertisement