

Median Formula and Step-by-Step Calculation
The concept of how to find the median plays a key role in mathematics and is widely applicable to both real-life situations and exam scenarios. Whether you need to analyze marks, salaries, or any data set, knowing how to find the median helps you identify the central value quickly and accurately.
What Is Median and How to Find It?
A median is defined as the middle value of a data set when the numbers are arranged in order from smallest to largest. Half of the values will be less than the median and half will be more. You’ll find this concept applied in statistics, data science, economics, and many areas where understanding the “typical” or “central” value is important. Median is especially useful when dealing with data that contains outliers or is not evenly distributed, unlike the mean.
Key Formula for Finding the Median
Here’s the standard formula for how to find the median, depending on whether you have an even or odd number of values:
For n (number of data values) odd:
Median = Value at position \( \left( \frac{n+1}{2} \right) \)
For n even:
Median = \( \frac{\text{(n/2)th value} + \text{((n/2)+1)th value}}{2} \)
How to Find the Median: Step-by-Step Guide
- Arrange the data in ascending (or descending) order.
- Count the total number of values (n).
-
If n is odd:
Find the value positioned at \( (n+1)/2 \), which is the median.
-
If n is even:
Find the values at positions n/2 and (n/2)+1, and take their average for the median.
Example (Odd): Find the median of 15, 7, 8, 17, 5.
- Arrange the data: 5, 7, 8, 15, 17
- Number of values (n) = 5 (odd)
- Median = value at position (5+1)/2 = 3. The 3rd value is 8.
- Final Answer: Median = 8
Example (Even): Find the median of 9.7, 6.3, 2.5, 7.1.
- Arrange the data: 2.5, 6.3, 7.1, 9.7
- Number of values (n) = 4 (even)
- Median = (2nd value + 3rd value) / 2 = (6.3 + 7.1)/2 = 6.7
- Final Answer: Median = 6.7
Median of Odd vs Even Data Sets
Type | How to Find Median | Example |
---|---|---|
Odd (n = 5) | Pick the value at position (n+1)/2 | 5, 7, 8, 15, 17 Median: 8 |
Even (n = 6) | Average values at n/2 and (n/2)+1 | 4, 12, 14, 17, 22, 35 Median: (17+22)/2 = 19.5 |
Median in Grouped or Frequency Data
How to find the median from grouped (frequency) data uses a different formula:
Median = \( l + \left( \frac{ \frac{n}{2} - c }{f} \right) \times h \)
- l = lower class boundary of median class
- n = total frequency
- c = cumulative frequency before median class
- f = frequency of median class
- h = width of the class interval
Example: Suppose cumulative frequency just before the median class is 15, the frequency of the median class is 12, its lower boundary is 54.5, class width is 5, and total n is 36. Then:
Median = 54.5 + ((18 - 15)/12) × 5 = 54.5 + (3/12) × 5 = 54.5 + 1.25 = 55.75
When to Use Median vs Mean vs Mode
Measure | What It Shows | Best Use |
---|---|---|
Median | Middle value; not affected by outliers | Skewed data, outliers present, non-numeric categories |
Mean | Average of all values | Evenly distributed, numeric data |
Mode | Most common value(s) | Data with repeats or categorical |
For a detailed comparison, visit our resource: Mean, Median, Mode.
Try These Yourself
- Find the median of 3, 9, 16, 25, 45, 21, 12.
- Calculate the median of 4, 7, 3, 17, 20, 11, 8.
- Given group data in a table, locate the median class and compute the median.
- Explain the difference between median and range for the set 8, 8, 10, 12, 7.
Frequent Errors and Misunderstandings
- Forgetting to order values before finding the median.
- Confusing mean and median, especially for even-sized lists.
- Mistaking the median as always being a value from the dataset (not true for even sets).
- Ignoring cumulative frequency when working with grouped data.
Relation to Other Concepts
The idea of how to find the median connects with other key topics like arithmetic mean, range, and quartiles. Mastering median calculation boosts your understanding of central tendency—a core part of descriptive statistics and many competitive exams.
Classroom Tip
A quick tip: When stuck, count your list, underline the two central numbers for even cases, and physically write out your calculation. Vedantu teachers encourage drawing a data line or using visual plots in live classes to help visualize the median.
We explored how to find the median—from its definition, formulas, and stepwise solutions to common mistakes. To master statistics, keep practicing different datasets and compare median with mean and mode. For more examples and explanations, join Vedantu's detailed median tutorial or check out cumulative frequency distribution for grouped data problems.
Quick Reference Table: Median Calculation
Step | Action | Odd n | Even n |
---|---|---|---|
1 | Order data (ascending) | Apply | Apply |
2 | Count n | Count | Count |
3 | Locate position | (n+1)/2 | n/2 and (n/2)+1 |
4 | Find median value | Direct value | Average of both |
Suggested Resources for Further Practice
- Mean, Median, Mode – Complete comparison and formulas
- How to Find the Mean – Master the arithmetic mean for deeper understanding
- Difference Between Mean, Median and Mode – Exam-focused explanation
- What is the Range of Data – Learn about range as a spread measure
- Cumulative Frequency Distribution – Key for grouped data problems
FAQs on How to Find the Median
1. How do I calculate the median?
To calculate the median, first arrange your numbers in ascending order. If you have an odd number of data points, the median is the middle value. If you have an even number of data points, the median is the average of the two middle values. For example, the median of 3, 5, 7, 9 is (5+7)/2 = 6.
2. What is the median of 7, 10, 7, 5, 9, 10?
First, arrange the numbers in ascending order: 5, 7, 7, 9, 10, 10. Since there are six numbers (an even number), the median is the average of the two middle numbers: (7 + 9) / 2 = 8.
3. How do I find the median for a data set with an even number of values?
When you have an even number of values, the median is found by calculating the average of the two middlemost numbers in your ordered data set. First, arrange the numbers in ascending order. Then, find the two middle numbers. Add those two numbers and divide the sum by 2. The result is your median.
4. Is there a formula for the median in statistics?
Yes, there are formulas for the median. For an odd number of values (n), the median is the ((n+1)/2)th value. For an even number of values, the median is the average of the (n/2)th and ((n/2)+1)th values. Remember to arrange the data in ascending order first.
5. How do you find the median in a stem-and-leaf plot or dot plot?
To find the median in a stem-and-leaf plot or dot plot, first list all the values in ascending order. Then, apply the standard median calculation method for either an odd or even number of values, as described above.
6. What happens if data points are repeated? Does it affect the median?
Repeated values do not change the *position* of the median; however, they can affect the *value* of the median. The median remains the middle value or the average of the two middle values in the ordered data set. Repeated values simply mean that the same value may be used multiple times in calculating the median.
7. Can the median ever not be a number in the data set?
Yes, this is possible when there is an even number of values in the data set. In this case, the median is the average of the two middle values, and this average might not be one of the original numbers in the data set.
8. How is the median calculated in grouped frequency distributions?
For grouped data, the median is calculated using a formula that involves the cumulative frequency and the class intervals. It's more complex than calculating the median for ungrouped data and often requires finding the median class first.
9. Why is sorting the data set essential before finding the median?
Sorting the data set (arranging it in ascending or descending order) is essential because the median represents the middle value or the average of the middle values. Without sorting, you cannot accurately identify the middle value(s).
10. When might the median be a better measure than the mean?
The median is often preferred over the mean when your data set includes outliers or is not uniformly distributed. The median is less sensitive to extreme values than the mean, providing a more robust measure of central tendency in such cases.
11. How do you estimate the median for a data set given as intervals?
When data is presented as intervals (e.g., in a histogram), you'll need to use cumulative frequency and identify the median class (the interval containing the median). Then, interpolation is often used to estimate the precise median value within that class.
12. What is the difference between the median and the mean?
The mean is the average of all values in a data set, calculated by summing all values and dividing by the number of values. The median is the middle value in an ordered data set (or average of the two middle values for an even number of data points). The median is less affected by outliers than the mean.

















