How to Calculate Standard Deviation for Grouped Data

Enter a value or class interval on each line with its frequency. The calculator finds midpoints, weighted mean, variance, and sample or population standard deviation with a checkable table.

Written and checked by TheToolNet Editorial Team · Last reviewed: August 22, 2026 · How we check statistics tools

Population formula
σ = √[Σf(x − μ)² ÷ Σf]

For class intervals, x is the class midpoint. For a sample, use total frequency minus one in the denominator.

Grouped-data standard deviation calculator

Use one row per class: value, frequency or lower-upper, frequency. Interval results are estimates based on midpoints.

Grouped standard deviation steps

  1. For each class interval, calculate midpoint x = (lower + upper) ÷ 2.
  2. Multiply every midpoint by its frequency and add: Σfx.
  3. Divide by total frequency N = Σf to get the weighted mean.
  4. Calculate f(x − mean)² for each row and add those values.
  5. Divide by N for a population or N − 1 for a sample, then take the square root.

Why grouped-data results use class midpoints

A frequency table with intervals does not preserve each raw observation. Replacing every observation in a class with the class midpoint is therefore an approximation. Narrow, sensible classes generally lose less information than wide classes, but the exact raw-data SD cannot be reconstructed unless the original values or additional sufficient statistics are available.

For a discrete frequency table such as value 3 occurring five times, no midpoint approximation is needed; the repeated value is known exactly.

Sample versus population grouped SD

Choose population SD when the table contains every member of the population you want to describe. Choose sample SD when those observations are a sample used to estimate a larger population’s spread. The calculator uses N − 1 for the sample version and N for the population version.

Worked midpoint example

For the class 10–20, the midpoint is 15. If its frequency is 3, its weighted contribution is fx = 45 and fx² = 675. Repeat for every class, sum the columns, and use the weighted mean and variance formulas. The calculator prints these columns so you can compare your written working line by line.

Frequently asked questions

Is grouped-data standard deviation exact?

It is exact for known discrete values with frequencies. It is normally an estimate for class intervals because their raw observations are unknown.

How do I find a class midpoint?

Add the lower and upper class limits and divide by two.

Do I divide by N or N − 1?

Use N for a complete population and N − 1 for a sample used to estimate population variance.

Can frequencies be decimals?

No. This tool treats frequency as a count, so it must be a positive whole number.

Related tools and references

Use the pooled SD calculator when you know each independent group’s n and sample SD, or see relative SD in Excel for a scale-free percentage.