The formula for variance and standard deviation for grouped data is very similar to the formula for ungrouped data. Below we show the formula for ungrouped data and grouped data.
Variance for grouped data
deviation  population  sample 
Ungrouped data  $$ Variance = frac {Σ (x – µ) ^ {2}} {N} $$  $$ Variance = frac {Σ (x – bar x) ^ {2}} {n – 1} $$ 
Grouped data  $$ Variance = frac {Σf (m – µ) ^ {2}} {N} $$  $$ Variance = frac {Σf (m – bar x) ^ {2}} {n – 1} $$ 
For grouped data, m is the midpoint of a class and f is the frequency of a class.
Did you notice the resemblance? Remember that a class is a group of values like 13 that includes 1, 2, and 3.
For grouped data, we’ll use the midpoint of a class instead of x or the exact value. Then, just like with the mean, we multiply the numerator by f or the frequency before we add the sum.
To get the standard deviation, just take the square root of the variance. To get the variance, simply increase the standard deviation to the power of 2.
Standard deviation for grouped data
Standard deviation  population  sample 
Ungrouped data  $$ σ = sqrt { frac {Σ (x – µ) ^ {2}} {N}} $$  $$ s = sqrt { frac {Σ (x – bar x) ^ {2}} {n – 1}} $$ 
Grouped data  $$ σ = sqrt { frac {Σf (m – µ) ^ {2}} {N}} $$  $$ s = sqrt { frac {Σf (m – bar x) ^ {2}} {n – 1}} $$ 
Let s be the standard deviation of the sample, then s² is the sample variance.
$$ s = sqrt {s ^ {2}} $$
Let σ be the population standard deviation, then σ² is the population variance.
$$ σ = sqrt {σ ^ {2}} $$

Chebyshev’s theorem
May 31, 21:32 a.m.
What is Chebyshev’s theorem? Definition and simple examples to help you understand quickly.
Continue reading