Grouped Data Standard Deviation Calculator

This grouped data standard deviation calculator finds the estimated mean, variance and standard deviation for data given as class intervals or as value-frequency pairs. Enter your classes and frequencies, and it shows the full midpoint working table (f·m and f·m²), the population and sample results, and a frequency chart — free, with no sign-up.

Grouped Data Standard Deviation Calculator

Enter class intervals with frequencies, or switch to value–frequency pairs. Results are estimates based on class midpoints.

Lower boundUpper boundFrequency (f)

Total frequency (Σf)20
Σf·m320.000
Estimated mean (x̄)16.000
Σf·m²6,300.000
Population variance (σ²)59.000
Population SD (σ)7.681
Sample variance (s²)62.105
Sample SD (s)7.881

Frequency by class chart

Frequency in each class. In value–frequency mode the bars show the frequency of each value.

Calculation ledger

Class / valueMidpoint (m)Frequency (f)f·mf·m²

What is grouped data standard deviation?

Grouped data standard deviation is the standard deviation of data that has been summarised into a frequency table — either as class intervals, such as 0–10, 10–20 and 20–30, or as values with frequencies, such as the value 4 occurring 5 times. Because the individual values are no longer visible, the calculation uses the midpoint of each class as a stand-in for every value inside it. The result is therefore an estimate, not an exact value. It is the right measure when only the table survives — in published survey results, exam mark distributions or grouped census data, for example. If you still have the raw values, use the standard deviation calculator instead.

How do you calculate standard deviation for grouped data?

Work through the frequency table one column at a time:

  1. Find the midpoint of each class. Add the lower and upper bound and divide by two: m = (lower + upper) / 2. For the class 10–20, the midpoint is 15.
  2. Multiply each midpoint by its frequency. Work out f·m for every class, and f·m² by multiplying f·m by m again.
  3. Add up the columns. Find the total frequency Σf, the total Σf·m and the total Σf·m².
  4. Calculate the estimated mean. Divide Σf·m by Σf: x̄ = Σf·m / Σf.
  5. Calculate the variance. For a population, σ² = Σf·m² / Σf − x̄². For a sample, s² = (Σf·m² − (Σf·m)² / Σf) / (Σf − 1).
  6. Take the square root. The standard deviation is the square root of the variance: σ = √σ² for a population, or s = √s² for a sample.

Worked example. Take the classes 0–10 (f = 5), 10–20 (f = 8) and 20–30 (f = 7). The midpoints are 5, 15 and 25, so Σf = 20, Σf·m = 320 and the estimated mean is 16.00. Σf·m² = 6,300, so the population variance is 6,300 / 20 − 16² = 59 and the population standard deviation is 7.681. The sample variance is 62.105 and the sample standard deviation is 7.881. The calculator above shows every step in its ledger. For the general method, see our guide on how to calculate standard deviation.

Why is the result an estimate?

When data are grouped, the exact values inside each class are lost: all we know is how many observations fell in the class, not where they sat within it. The midpoint method replaces every value in a class with the class midpoint, so the spread of values inside each class is ignored. The result is usually close to the standard deviation of the raw data — and it is the best estimate available from the table — but it is not exact. Narrow classes give a more accurate estimate than wide ones. The NIST/SEMATECH e-Handbook of Statistical Methods defines variance and standard deviation from the mean and explains how grouping into classes summarises the data; once the raw values are gone, only an approximation can be recovered.

When should you use grouped data standard deviation?

Use it whenever your data arrive as a frequency table rather than as a list of values: published tables of exam marks, survey responses grouped into ranges, income bands, age groups or any histogram-style summary. It is also the natural choice when the classes are the only record you have. The calculator accepts both class intervals and value–frequency pairs, so it covers grouped ranges and discrete grouped values. If your values carry different weights rather than frequencies, the weighted standard deviation calculator is the matching tool, and if you need to combine two samples, use the pooled standard deviation calculator.

Grouped data SD vs ordinary standard deviation

The two measures answer the same question — how spread out are the values — but they start from different data:

Grouped data SDOrdinary (ungrouped) SD
Data you start withA frequency table of classes or valuesEvery individual value
What you useClass midpoints and frequenciesThe values themselves
ResultAn estimateExact
Use it whenOnly the table survivesYou have the raw data

Which of the population and sample formulas to use is a separate choice: read population vs sample standard deviation if you are unsure. Both versions are shown by this calculator, so you can take whichever fits your data.

How to calculate grouped data standard deviation in Excel

In Excel, put the class midpoints in one column and the frequencies in the next. Use SUMPRODUCT to find Σf·m (multiply the midpoint column by the frequency column and add the results) and Σf·m² (multiply the squared midpoints by the frequencies). Divide Σf·m by Σf for the mean, then apply σ² = Σf·m² / Σf − mean² and take the square root for the population SD. For the sample version, use s² = (Σf·m² − (Σf·m)² / Σf) / (Σf − 1) instead. The calculator on this page does the same arithmetic and shows the working, so you can check your spreadsheet against it.

Frequently asked questions

What is the formula for grouped data standard deviation?

First find each class midpoint m = (lower + upper) / 2. The estimated mean is x̄ = Σf·m / Σf. The estimated population variance is σ² = Σf·m² / Σf − x̄², and the population standard deviation is σ = √σ². For a sample, use s² = (Σf·m² − (Σf·m)² / Σf) / (Σf − 1) and s = √s².

How do I find the midpoint of a class interval?

Add the lower and upper bounds of the class and divide by two: m = (lower + upper) / 2. For the class 10–20, the midpoint is (10 + 20) / 2 = 15. The midpoint stands for every value in that class, which is why the result is an estimate.

Is grouped data standard deviation exact or an estimate?

It is an estimate. Because the original values are lost when data are grouped, the calculation treats every value in a class as if it were the class midpoint. The result is close to the true standard deviation when classes are narrow, but it is not exact.

Should I use the population or sample standard deviation for grouped data?

Use the population standard deviation (σ) when your frequency table covers the whole group you are describing, and the sample standard deviation (s) when the table is a sample from a larger population. This calculator shows both, so you can pick the one that fits your data.

What is the difference between grouped and ungrouped standard deviation?

Ungrouped standard deviation is calculated from every individual value. Grouped standard deviation is calculated from a frequency table, using class midpoints (or values) and their frequencies. Grouped data is used when only the table survives, for example in published statistics or survey reports.

How do I calculate standard deviation for grouped data in Excel?

In Excel, list the midpoints in one column and the frequencies in the next. Use SUMPRODUCT to get Σf·m and Σf·m², divide by Σf for the mean, then apply σ² = Σf·m² / Σf − mean² and take the square root. For the sample version, use the (Σf·m² − (Σf·m)² / Σf) / (Σf − 1) formula instead.

What happens if my class intervals have different widths?

The midpoint method still works: each class contributes its own midpoint, so different widths are handled naturally. Just make sure the classes do not overlap and that every observation falls in exactly one class. Very wide classes give a rougher estimate than narrow ones.

Can I use this calculator for value-frequency pairs?

Yes. Switch to the value–frequency mode, enter each value with its frequency, and the calculator treats each value as its own midpoint. For example, the values 2 (f = 3), 4 (f = 5) and 6 (f = 2) give an estimated mean of 3.80 and a population standard deviation of 1.400.

Keep exploring

Once you have the spread of your grouped data, the next step is often to standardise a value or to work with the distribution it came from. Try the z-score calculator to see how far a value sits from the mean in standard-deviation units, or the normal distribution calculator for probabilities and percentiles. You can also browse all statistics tools on the site. For the theory behind the formulas, see the NIST/SEMATECH e-Handbook of Statistical Methods (Measures of Scale).

More Tools to Explore