Study and Productivity

How to Find the Mean, Median and Mode of Grouped Data

Grouped frequency tables made simple: class marks, the direct and step-deviation mean, the median and mode formulas, ogives and a worked exam example.

Saizul Amin
Saizul Amin3 Nov 2026 · 4 min read
How to Find the Mean, Median and Mode of Grouped Data

How to Find the Mean, Median and Mode of Grouped Data

When data arrive as a frequency table with classes such as 0-10, 10-20 and 20-30, you no longer know the individual values. You can still estimate the mean, median and mode, using formulas that every secondary-school syllabus teaches, including NCERT Class 10 Mathematics. This guide explains each formula, works through one complete example and lists the slips that cost marks. Every step can be checked in the grouped data mean, median and mode calculator.

Class marks and boundaries

The class mark (mid-point) of a class is (lower limit + upper limit) / 2. It stands in for every value in that class.

If classes are written inclusively, such as 10-19 and 20-29, there is a gap of 1 between them. Before using the median or mode formula, convert them to class boundaries by subtracting half the gap from each lower limit and adding it to each upper limit: 9.5-19.5, 19.5-29.5, and so on. Exclusive classes such as 10-20 and 20-30 already touch and need no change.

The example

Marks of 50 students:

Marks0-1010-2020-3030-4040-50
Students5815166

The mean: direct method

Multiply each frequency by its class mark and divide by the total frequency N.

Σ f x = 5 × 5 + 8 × 15 + 15 × 25 + 16 × 35 + 6 × 45 = 25 + 120 + 375 + 560 + 270 = 1350.

Mean = 1350 / 50 = 27.

The mean: step-deviation method

When class marks are large, the step-deviation method keeps the arithmetic small. Choose an assumed mean A, usually a central class mark, and the common class width h. For each class compute u = (x − A) / h.

With A = 25 and h = 10, the values of u are −2, −1, 0, 1 and 2, and f × u gives −10, −8, 0, 16 and 12. Their sum is 10.

Mean = A + h × Σ f u / N = 25 + 10 × 10 / 50 = 27, the same answer. The two methods must always agree; if they do not, there is an arithmetic error.

The median

Find N / 2 = 25. Build the cumulative frequencies: 5, 13, 28, 44, 50. The median class is the first one whose cumulative frequency reaches 25, which is 20-30. Then

Median = l + ((N/2 − cf) / f) × h,

where l is the lower boundary of the median class (20), cf the cumulative frequency before it (13), f its frequency (15) and h the width (10).

Median = 20 + ((25 − 13) / 15) × 10 = 20 + 8 = 28.

The mode

The modal class has the highest frequency, here 30-40 with f₁ = 16. Take f₀ = 15 (the class before) and f₂ = 6 (the class after).

Mode = l + ((f₁ − f₀) / (2f₁ − f₀ − f₂)) × h = 30 + (1 / (32 − 21)) × 10 = 30 + 10/11 ≈ 30.91.

Checking with the empirical relation

For moderately skewed data, Mode ≈ 3 Median − 2 Mean. Here 3 × 28 − 2 × 27 = 30, close to 30.91. It is a sanity check, not an exact rule.

Ogives

A less-than ogive plots cumulative frequency against upper class boundaries; a more-than ogive plots it against lower boundaries. The two curves cross at the median, which gives a graphical way to find it. The calculator draws both ogives next to a histogram of the table.

Common mistakes

  • Using class limits instead of boundaries for inclusive classes.
  • Taking cf as the cumulative frequency of the median class itself rather than the class before it.
  • Choosing the modal class by the class mark instead of the frequency.
  • Forgetting that the mode formula needs equal class widths around the modal class.
  • When two classes tie for the highest frequency, the data are bimodal and the formula gives only one of the modes.

Practising and exporting

Enter your own table, or paste raw data and let the tool build classes of a chosen width. The practice tab generates new tables and checks your answers, and you can print the full working or export the table as CSV.

Limits

Grouped-data results are estimates, because the formulas assume values are spread evenly inside each class. They are not the same as the mean, median or mode of the original raw data. Open-ended classes such as "50 and above" have no class mark, so the mean cannot be computed without an assumption about their width.

Completely freeNo cost, no sign-up
Files stay privateEverything runs in your browser
Easy in your languageAvailable in many languages