Median of Grouped and Ungrouped Data: Formula, Calculator, Examples

Median of Grouped and Ungrouped Data: Formula, Calculator, Examples

Edited By Team Careers360 | Updated on Sep 24, 2024 10:08 AM IST

Median is one of the three types of central tendency. The median of a dataset is actually the middle value of the data. In this article, we will discuss the median of grouped data formula, the median of grouped data example, the median of grouped data calculator, the median of grouped data questions, the median of grouped data with unequal class sizes, the median of grouped data definition, the median of grouped data and ungrouped data, the median of grouped data cumulative frequency, the median of ungrouped data formula, example and questions etc.


Also, read the median of grouped data without class interval, the median of grouped data formula, the median of ungrouped data class 10, the median of ungrouped data example, the median of ungrouped data even, the median of ungrouped data with frequency, the median of ungrouped data when n is even, the median of ungrouped data worksheet, the median of ungrouped data definition, the median of ungrouped data questions.


Median of Grouped and Ungrouped Data: An Overview

Before we start to discuss the median, let’s have a quick look at the mean of grouped and ungrouped data. The mean is the average of the observations of the given data. To calculate the mean we need to add all the observations and divide it by the total number of observations.

What is the median?

The median is the value that separates a data set into two halves. For ungrouped data, it is the middle value when the data is ordered. For grouped data, it is the value corresponding to the cumulative frequency that reaches or exceeds half the total frequency.

How to calculate the median for Ungrouped data?

  • Step 1: Arrange the given values in ascending order.

  • Step 2: Find the number of observations in the given set of data, denoted by $n$.

  • Step 3: If $n$ is odd, the median equals the $(\frac{n+1}{2})$th observation.

  • Step 4: If $n$ is even, the median is given by the mean of the $(\frac{n}{2})$th observation and the $(\frac{n}{2}+1)$th observation.

Example: Find the median of the dataset: 5, 2, 9, 1, 6.

Arrange in ascending order: 1, 2, 5, 6, 9.

Number of observations, n = 5

Since $n$ is odd, the median = $(\frac{5+1}{2})$th observation = 3rd observation = 5

Hence, the required median is 5.


How to calculate the median for Grouped data?

Concept of Cumulative Frequency: Cumulative frequency is the running total of frequencies up to a certain class interval in a frequency distribution table. It helps in identifying the position of the median class in grouped data by showing how frequencies accumulate over the classes.

Steps to calculate the median for Grouped data

  • Step 1: Make a table with three columns: class interval, frequency ($f$), and cumulative frequency ($cf$).

  • Step 2: Write the class intervals and the corresponding frequency in the respective columns.

  • Step 3: Write the cumulative frequency in the $cf$ column by adding the frequency in each step.

  • Step 4: Find the sum of frequencies, ∑f. It will be the same as the last number in the cumulative frequency column.

  • Step 5: Find $\frac{n}{2}$ ($n$ is the total number of observations). Then find the class whose cumulative frequency is greater than and nearest to $\frac{n}{2}$. This is the median class.

  • Step 6: Use the formula for the median

Median = $l+\frac{\frac{n}{2}-cf}{f}×h$, where

$l$ = lower boundary of the median class

$n$ = total number of observations

$cf$ = cumulative frequency of the class preceding the median class

$f$ = frequency of the median class

$h$ = class interval size

Example:


Class Interval

Frequency($f$)

Cumulative Frequency($cf$)

0-10

7

7

10-20

9

7 + 9 = 16

20-30

10

7 + 9 + 10 = 26

30-40

14

7 + 9 + 10 + 14 = 40

40-50

10

7 + 9 + 10 + 14 + 10 = 50


Here, $\sum f$ = 50

Now $\frac{n}{2}$ = $\frac{50}{2}$ = 25

The class whose cumulative frequency is greater than and nearest to 25 is (20-30).

Thus, the median class is (20-30).

Using the formula we get,

Median = $20+\frac{\frac{50}{2}-16}{10}×10$ = $20+9$ = $29$

Hence, the required median is 29.

What does the median signify?

The median signifies the middle value of a data set, providing a measure of central tendency that is less affected by outliers and skewed data. It divides the data set into two equal halves, with 50% of the observations lying below the median and 50% above it.

Important points

  • The median is not affected by extreme values.

  • It is suitable for ordinal and interval data.

  • For a perfectly symmetrical distribution, the mean and median are equal.

Practice Questions/Solved Examples

Q.1.

The median of the following data will be _________.

32, 25, 33, 27, 35, 29, and 30

  1. 32

  2. 27

  3. 30

  4. 29

Hint: The median of this data is the middlemost number of this data (as the total number of data is odd).

Solution:

Given numbers:

32, 25, 33, 27, 35, 29, and 30

⇒ the given data is in ascending order = 25, 27, 29, 30, 32, 33, 35

The median of this data is the middlemost number of this data (as the total number of data is odd)

So, median term = $[\frac{7 + 1}{2}]^{th}$

= $[\frac{8}{2}]^{th}$

= $4^{th}$ term

⇒ Median = 30

Hence, the correct answer is 30.


Q.2.

The median of a set of 11 distinct observations is 73.2. If each of the largest five observations of the set is increased by 3, then the median of the new set__________.

  1. is 3 times that of the original set

  2. is increased by 3

  3. remains the same as that of the original set

  4. is decreased by 3

Hint: Use the formula:

Median of set of $n$ observation = $[\frac{(n+1)}{2}]^{th}$ observation

Solution:

Median of set of $n$ observation = $[\frac{(n+1)}{2}]^{th}$ observation

Even if the largest 5 observations are increased by 3, the 6th observation remains the same.

Therefore, the median of the new set remains the same.

Hence, the correct answer is ‘remains the same as that of the original set’.


Q.3.

The median of a set of 9 distinct observations is 20.5. If each of the largest 4 observations of the set is increased by 2, then the median of the new set is:

  1. is decreased by 2

  2. is two times the original median

  3. remains the same as that of the original set

  4. is increased by 2

Hint: Median of set of $n$ observation = $[\frac{(n+1)}{2}]^{th}$ observation

Solution:

Median of set of $n$ observation = $[\frac{(n+1)}{2}]^{th}$ observation

Even if the largest 4 observations are increased by 2, the 5th observation remains the same.

Therefore, the median of the new set remains the same.

Hence, the correct answer is ‘remains the same as that of the original set’.


Q.4.

Calculate the value of the median for the following data distribution:

Class Interval

0-10

10-20

20-30

30-40

40-50

Frequency

5

7

12

10

6


  1. 26.67

  2. 24.47

  3. 22

  4. 19.67

Hint: Use the formula for the median

Median = $l+\frac{\frac{n}{2}-cf}{f}×h$, where

$l$ = lower boundary of the median class

$n$ = total number of observations

$cf$ = cumulative frequency of the class preceding the median class

$f$ = frequency of the median class

$h$ = class interval size

Solution:

Class Interval

Frequency($f$)

Cumulative Frequency($cf$)

0-10

5

5

10-20

7

5 + 7 = 12

20-30

12

5 + 7 + 12 = 24

30-40

10

5 + 7 + 12 + 10 = 34

40-50

6

5 + 7 + 12 + 10 + 6 = 40


Here, $\sum f$ = 40

Now $\frac{n}{2}$ = $\frac{40}{2}$ = 20

The class whose cumulative frequency is greater than and nearest to 20 is (20-30).

Thus, the median class is (20-30).

Using the formula we get,

Median = $20+\frac{\frac{40}{2}-12}{12}×10$ = $20+\frac{8}{12}×10$ = $26.67$

Hence, the correct answer is 26.67.


Q.5.

Find the median age of employees working at XYZ organization, based on the following data:


Ages (in years)

25-30

30-35

35-40

40-45

45-50

No. of Employees

8

12

10

5

3

  1. 44.58

  2. 35.58

  3. 40.58

  4. 34.58

Hint: Use the formula for the median

Median = $l+\frac{\frac{n}{2}-cf}{f}×h$, where

$l$ = lower boundary of the median class

$n$ = total number of observations

$cf$ = cumulative frequency of the class preceding the median class

$f$ = frequency of the median class

$h$ = class interval size

Solution:

Ages (in years)

No. of Employees($f$)

Cumulative Frequency($cf$)

25-30

8

8

30-35

12

8 + 12 = 20

35-40

10

8 + 12 + 10 = 30

40-45

5

8 + 12 + 10 + 5 = 35

45-50

3

8 + 12 + 10 + 5 + 3 = 38


Here, $\sum f$ = 38

Now $\frac{n}{2}$ = $\frac{38}{2}$ = 19

The class whose cumulative frequency is greater than and nearest to 19 is (30-35).

Thus, the median class is (30-35).

Using the formula we get,

Median = $30+\frac{\frac{38}{2}-8}{12}×5$ = $30+\frac{11}{12}×5$ = $34.58$

Hence, the correct answer is 34.58.


Q.6.

Find the median score of a cricket team in the past 20 matches based on the following data:


Scores

80-100

100-120

120-140

140-160

160-180

No. of matches

3

7

4

4

2


  1. 123

  2. 125

  3. 124

  4. 126

Hint: Use the formula for the median

Median = $l+\frac{\frac{n}{2}-cf}{f}×h$, where

$l$ = lower boundary of the median class

$n$ = total number of observations

$cf$ = cumulative frequency of the class preceding the median class

$f$ = frequency of the median class

$h$ = class interval size

Solution:

Scores

No. of matches($f$)

Cumulative Frequency($cf$)

80-100

3

3

100-120

6

3 + 6 = 9

120-140

4

3 + 6 + 4 = 13

140-160

4

3 + 6 + 4 + 4 = 17

160-180

3

3 + 6 + 4 + 4 + 3 = 20


Here, $\sum f$ = 20

Now $\frac{n}{2}$ = $\frac{20}{2}$ = 10

The class whose cumulative frequency is greater than and nearest to 10 is (120-140).

Thus, the median class is (120-140).

Using the formula we get,

Median = $120+\frac{\frac{20}{2}-9}{4}×20$ = $120+\frac{1}{4}×20$ = $125$

Hence, the correct answer is 125.


Q.7.

Find the median height of students in a class based on the following data:


Heights (in cms)

152-156

156-160

160-164

164-168

168-172

No. of students

8

7

12

2

1


  1. 162

  2. 158

  3. 160

  4. 155

Hint: Use the formula for the median

Median = $l+\frac{\frac{n}{2}-cf}{f}×h$, where

$l$ = lower boundary of the median class

$n$ = total number of observations

$cf$ = cumulative frequency of the class preceding the median class

$f$ = frequency of the median class

$h$ = class interval size

Solution:

Heights (in cms)

No. of students($f$)

Cumulative Frequency($cf$)

152-156

8

8

156-160

7

8 + 7 = 15

160-164

12

8 + 7 + 12 = 27

164-168

2

8 + 7 + 12 + 2 = 29

168-172

1

8 + 7 + 12 + 2 + 1 = 30


Here, $\sum f$ = 30

Now $\frac{n}{2}$ = $\frac{30}{2}$ = 15

The class whose cumulative frequency is greater than and nearest to 15 is (160-164).

Thus, the median class is (160-164).

Using the formula we get,

Median = $160+\frac{\frac{30}{2}-15}{12}×4$ = $160+\frac{0}{12}×4$ = $160$

Hence, the correct answer is 160.

Frequently Asked Questions (FAQs)

1. What is the formula to find the median?

If $n$ is odd, the median equals the $(\frac{n+1}{2})$th observation.

If $n$ is even, the median is given by the mean of the $(\frac{n}{2})$th observation and the $(\frac{n}{2}+1)$th observation.

2. What is the difference between mean and median? Answer: The mean is the average of a data set, calculated by adding all the values together and dividing by the number of values. The median is the middle value in a data set when the values are arranged i

The mean is the average of a data set, calculated by adding all the values together and dividing by the number of values. The median is the middle value in a data set when the values are arranged in ascending or descending order.

3. What is the median class?

The median class in a frequency distribution is the class interval that contains the median value of the data set. It is determined by locating the cumulative frequency that reaches or exceeds half the total number of observations.

4. What is the cumulative frequency?

Cumulative frequency is the running total of frequencies up to a certain class interval in a frequency distribution table. It helps in identifying the position of the median class in grouped data by showing how frequencies accumulate over the classes.

5. Is media a central tendancy?

Yes, median is a central tendency.

Articles

Get answers from students and experts
Back to top