Separate the numbers with commas, spaces or new lines. You can use decimals and negative numbers. Up to 10,000 numbers.
Choose Sample if your numbers are only part of a bigger group. Choose Population if they are the whole group.
Sample variance
-
Working: difference from the mean
| Number | Difference from mean | Squared |
|---|
What is variance and how do you calculate it?
Variance measures how far a set of numbers is spread out from its average. It is the average of the squared differences from the mean. A small variance means the numbers are close together, and a large variance means they are widely scattered.
Sample variance: s² = Σ(x − mean)² ÷ (n − 1)
Standard deviation = √variance
Steps
- Add up the numbers and divide by how many there are, to get the mean.
- Subtract the mean from each number.
- Square each of those differences.
- Add the squares together.
- Divide by n for a population, or by n − 1 for a sample.
Example
Take the numbers 2, 4, 4, 4, 5, 5, 7, 9. The mean is 5. The squared differences are 9, 1, 1, 1, 0, 0, 4 and 16, which add up to 32. For a population, the variance is 32 ÷ 8 = 4. For a sample, it is 32 ÷ 7 = 4.571.
Sample or population?
Use population when your numbers are every value in the group you care about, such as the marks of all students in one class. Use sample when your numbers are only a part of a larger group, such as a survey of 200 people out of a city. Dividing by n − 1 for a sample corrects for the fact that a sample tends to understate the true spread. If you are unsure, sample is the usual choice.
Variance or standard deviation?
- Variance is in squared units. If your data is in rupees, the variance is in rupees squared, which is hard to picture.
- Standard deviation is the square root of the variance, so it is in the same units as your data. It is easier to read.
- Variance is still useful, because variances of independent values can be added together, which is not true of standard deviations.
- A variance of 0 means every number is the same.
- Variance can never be negative.
For the standard deviation as the main result, use the Standard Deviation Calculator. For the average, middle value and most common value, use the Mean Median Mode Calculator.
Related calculators
Standard Deviation Calculator
Find the spread of a list of numbers, for a sample or a population.
Use calculator →Mean Median Mode Calculator
Find the average, middle value and most common value of a list.
Use calculator →Percentage Difference Calculator
Compare two numbers with the percentage difference.
Use calculator →