How to Use the Variance Calculator
This variance calculator helps you find the sample variance or population variance of a dataset. It also provides a clear, step-by-step solution to help you learn how to find these variances for your data.
To use the calculator:
- Select the correct type of data. You should select the sample option if the data values are drawn from a larger population or the population option if your data values represent the entire group you want to study.
- Enter your data values. You can either type or paste your numbers into the data input field. This calculator accepts data values separated using commas, spaces, tabs, or line breaks. You can also paste values directly from Excel or Google Sheets.
- Click Calculate.
The calculator will instantly return the correct variance for your data, and show you exactly how to find the variance by hand, step-by-step.
Want to calculate the sample or population standard deviation instead? Use the standard deviation calculator to get instant answers, with a clear, step-by-step solution.
Example 1. Find the Sample Variance Using the Calculator
Suppose a researcher records the following sample data:
7, 9, 10, 12, 14, 16
Find the sample variance.
Solution
To find the sample variance using the calculator:
- Select the Sample option.
- Copy and paste the sample data into the data input field.
- Click Calculate.
The calculator will compute the sample variance and give the answer as: Sample Variance, s² = 11.066667. It will also show you how the sample variance was computed for this dataset, step-by-step.
Example 2. Find the Population Variance Using the Calculator
Suppose a small business records the number of orders received over five complete working days:
20, 26, 16, 17, 22
Find the population variance.
Solution
Since the data includes all working days in the period being studied, we can treat it as population data.
To find the population variance using the calculator:
- Select the Population option.
- Copy and paste the data values into the data input field.
- Click Calculate.
The calculator will instantly return the correct population variance for your data as: Population Variance, σ² = 12.96. It will also show you how this variance was calculated using your data, step-by-step.
What Is Variance?
Variance is a measure of dispersion that helps us understand how much the values in a dataset vary from the mean. In other words, it measures the average squared distance between each data value and the mean.
Variance is useful because it helps you understand the spread of data. However, because variance uses squared deviations, its units are also squared. This is why many people also calculate the standard deviation by finding the square root of the variance to express this variation in the original units of the data.
Types of Variance
The two common types of variance are:
- Population variance, which measures the spread of all values in an entire population.
- Sample variance, which measures the spread of values in a sample taken from a larger population.
The calculation process is almost the same for both. The main difference is the denominator, where we divide the sum of squared deviations by N for the population variance and by n-1 for the sample variance.
Population Variance
The population variance is a measure of dispersion, which tells us how much the entire population varies from the population mean. In statistics, the population variance symbol is σ².
Since every member of the population is studied, we divide the squared deviations from the population mean by N. In this case, N is the total number of observations in the population.
In simple terms, the population variance tells you the average squared distance between the population values and the population mean.
Population Variance Formula
The population variance formula is:

Where:
- σ² is the population variance.
- μ is the population mean.
- xi is each individual data value.
- N is the total number of values in the population.
- Σ is the summation symbol.
While the formula may seem complex, its application is simple. You calculate how far each value is from the population mean, square each deviation, add the squared deviations, and divide by the total number of values in the population.
Alternative Population Variance Formula
The population variance can also be calculated using an alternative formula, sometimes called the shortcut formula or computational formula. This formula is common in statistics work because it allows you to quickly find the population variance from summary statistics such as Σxi², N, and μ.
The alternative population variance formula is:

σ² = [Σxi² − Nμ²] / N
Where:
- σ² is the population variance.
- xi is each individual data value.
- Σxi² is the sum of the squared values.
- μ is the population mean.
- N is the total number of values in the population.
This alternative formula gives the same answer as the main population variance formula. While the main formula is often easier to understand because it clearly shows that variance is based on distance from the mean, the alternative formula can be faster when you already have Σxi² and μ.
Let’s learn how to find the population variance with an example.
How to Find Population Variance by Hand
To find the population variance manually, you can either use the main population variance formula or the alternative shortcut formula. In this section, we demonstrate that both methods arrive at the same answer using the following example.
Example. Find the population variance for the following dataset:
10, 12, 14, 16, 18
Since the values represent the entire group being studied, we use the population variance formula.
Method 1. Using the Main Population Variance Formula
To compute the population variance manually using the main population variance formula, follow these steps.
Step 1: Calculate the Population Mean, μ
You find the population mean, μ, by adding all data values in the population data and dividing the result by the total number of observations in that population.
By definition, the population mean formula is: μ = Σxi / N
From the dataset:
Σxi = 10 + 12 + 14 + 16 + 18
= 70
Additionally, there are 5 observations in the population. Hence, N = 5
Substituting the values into the population mean formula and solving gives:
μ = 70 / 5
= 14
Therefore, the population mean is: μ = 14
Want a quick way to find the mean for your population data? Use the mean calculator to get instant results with a clear, step-by-step solution.
Step 2: Find Each Deviation from the Population Mean
This step involves subtracting the population mean from each data value to get the deviations from the mean, xi − μ. The table below demonstrates how to compute the deviations from the population mean.
| Observation, xi | Deviation from the mean, xi − μ |
|---|---|
| 10 | 10 − 14 = -4 |
| 12 | 12 − 14 = -2 |
| 14 | 14 − 14 = 0 |
| 16 | 16 − 14 = 2 |
| 18 | 18 − 14 = 4 |
Step 3: Square Each Deviation
Next, square each deviation to remove the negative values. This gives (xi − μ)². Therefore, the table in step 2 can be updated as follows.
| Observation, xi | Deviation from the mean, xi − μ | Squared deviation, (xi − μ)² |
|---|---|---|
| 10 | 10 − 14 = -4 | (-4)² = 16 |
| 12 | 12 − 14 = -2 | (-2)² = 4 |
| 14 | 14 − 14 = 0 | 0² = 0 |
| 16 | 16 − 14 = 2 | 2² = 4 |
| 18 | 18 − 14 = 4 | 4² = 16 |
Step 4: Add the Squared Deviations
From the population variance formula, the term Σ(xi − μ)² is called the sum of squared deviations. We can find this value by adding all values in the squared deviation column.
Therefore, Σ(xi − μ)² = 16 + 4 + 0 + 4 + 16
= 40
Therefore, Σ(xi − μ)² = 40
Step 5: Divide the Sum of Squared Deviations by N
Dividing the sum of squared deviations by N gives the population variance. In other words, population variance, σ² = Σ(xi − μ)² / N
Substituting the values into the formula and solving gives:
σ² = 40 / 5
= 8
Therefore, the population variance, σ² = 8
Method 2. Using the Alternative Population Variance Formula
By definition, the alternative population variance formula is:
σ² = [Σxi² − Nμ²] / N
From the formula, we need to find the sum of squared values, Σxi², the population size, N, and the population mean, μ. Therefore, to find the population variance using this alternative method, follow these steps:
Step 1: Find the Sum of Squared Values, Σxi²
From the dataset: 10, 12, 14, 16, 18
Therefore, Σxi² = 10² + 12² + 14² + 16² + 18²
= 100 + 144 + 196 + 256 + 324
= 1020
Therefore, Σxi² = 1020
Step 2: Find the Population Mean
From Method 1, we already know the population mean, μ = 14 and N = 5
Step 3: Substitute the Values into the Alternative Formula
By definition, the alternative population variance formula is: σ² = [Σxi² − Nμ²] / N
Substituting the values into the formula and solving, we get:
σ² = [1020 − 5(14)²] / 5
= [1020 − 5(196)] / 5
= 40 / 5
Thus, σ² = 8
Therefore, the population variance, σ² = 8
Observe. Both methods yield the same population variance. This implies that both formulas are correct, and it is up to you to choose the method that feels easier for your calculation.
Note: You should use the population variance when:
- The dataset includes all members of the population.
- No inference about a larger group is required.
- The data represent complete records, such as all employees in a company or all scores in a class.
- You want to describe the spread of the entire group being studied.
Sample Variance
The sample variance is a measure of dispersion that tells us how much the values in a sample vary from the sample mean. It is commonly used to estimate the population variance when it is not possible or practical to collect data from the whole population. In statistics, the sample variance symbol is s².
Unlike the population variance, which includes every member of the population, the sample variance is based on only part of the population. Because of this, we divide the squared deviations by n − 1 instead of N, where n is the total number of values in the sample data. This adjustment is known as Bessel’s correction.
In simple terms, the sample variance tells you the average squared distance between the sample values and the sample mean, adjusted for the fact that the data are only a sample.
Sample Variance Formula
The sample variance formula is:

Where:
- s² is the sample variance.
- x̄ is the sample mean.
- xi is each individual data value.
- n is the total number of values in the sample.
- Σ is the summation symbol.
Although the formula may appear complex, its application follows a clear process. You calculate how far each value is from the sample mean, square each deviation, add the squared deviations, and divide by n − 1.
The key difference between the sample and population variance formulas is the denominator. Specifically, while the sample variance divides the sum of squared deviations by n − 1, the sum of squared deviations for the population variance is divided by N.
Alternative Sample Variance Formula
The sample variance can also be calculated using an alternative formula, sometimes called the shortcut formula or computational formula. This formula is useful when you already have summary statistics such as Σxi², n, and x̄.
The alternative sample variance formula is:

Where:
- s² is the sample variance.
- xi is each individual data value.
- Σxi² is the sum of the squared values.
- x̄ is the sample mean.
- n is the total number of values in the sample.
This alternative formula gives the same answer as the main sample variance formula. While the main formula is often easier for beginners because it clearly shows the deviations from the mean, the alternative formula can be faster when you already have Σxi² and x̄.
How to Find Sample Variance by Hand
To find the sample variance manually, you can either use the main sample variance formula or the alternative shortcut formula. In this section, we demonstrate that both methods arrive at the same answer using the following example.
Example. Find the sample variance for the following dataset: 10, 8, 11, 16, 14
Method 1. Using the Main Sample Variance Formula
Since these values are treated as a sample drawn from a larger population, we use the sample variance formula and follow these steps:
Step 1: Calculate the Sample Mean, x̄
By definition, the sample mean formula is: x̄ = Σxi / n
From the dataset: Σxi = 10 + 8 + 11 + 16 + 14
= 59
There are also 5 observations in the sample data. Hence, n = 5
Applying the sample mean formula and substituting the values gives:
x̄ = 59 / 5
= 11.8
Therefore, the sample mean, x̄ = 11.8
Step 2: Find Each Deviation from the Sample Mean
This step involves subtracting the sample mean from each data value to get the deviations from the mean, xi − x̄. The table below demonstrates how to find these deviations.
| Observation, xi | Deviation from the mean, xi − x̄ |
|---|---|
| 10 | 10 − 11.8 = -1.8 |
| 8 | 8 − 11.8 = -3.8 |
| 11 | 11− 11.8 = -0.8 |
| 16 | 16 − 11.8 = 4.2 |
| 14 | 14 − 11.8 = 2.2 |
Step 3: Square Each Deviation
Next, square each deviation to remove the negative values. This gives (xi − x̄)².
| Observation, xi | Deviation from the mean, xi − x̄ | Squared deviation, (xi − x̄)² |
|---|---|---|
| 10 | 10 − 11.8 = -1.8 | (-1.8)2 = 3.24 |
| 8 | 8 − 11.8 = -3.8 | (-3.8)2 = 14.44 |
| 11 | 11− 11.8 = -0.8 | (-0.8)2 = 0.64 |
| 16 | 16 − 11.8 = 4.2 | (4.2)2 = 17.64 |
| 14 | 14 − 11.8 = 2.2 | (2.2)2 = 4.84 |
Step 4: Add the Squared Deviations
From the sample variance formula, the term Σ(xi-x̄ )² is called the sum of squared deviations. We can find this value by adding all values in the squared deviation column.
Therefore, Σ(xi − x̄)² = 3.24 + 14.44 + 0.64 + 17.64 + 4.84
= 40.8
Hence, Σ(xi − x̄)² = 40.8
Step 5: Divide the results in Step 4 by n − 1
Dividing the sum of squared deviations by n − 1 gives the sample variance. In other words, s² = Σ(xi − x̄)² / (n − 1)
Substituting the values into the formula and solving gives:
s² = 40.8/(5-1)
= 40.8/4
= 10.2
Therefore, the sample variance, s² = 10.2
Method 2. Using the Alternative Sample Variance Formula
By definition, the alternative sample variance formula is: s² = [Σxi² − nx̄²] / (n − 1)
From the formula, we need to find the sum of squared values, Σxi², the sample size, n, and the sample mean, x̄. To find these unknowns, follow these steps:
Step 1: Find the Sum of Squared Values, Σxi²
From the dataset: 10, 8, 11, 16, 14, we can find the sum of squared values, Σxi², as follows
Σxi² = 10² + 8² + 11² + 16² + 14²
= 100 + 64 + 121 + 256 + 196
= 737
Step 2: Find the Sample Mean
From Method 1, we already found that the sample mean, x̄ = 11.8, and n = 5
Step 3: Substitute the Values into the Alternative Formula
By definition, the alternative sample variance formula is: s² = [Σxi² − nx̄²] / (n − 1)
Substituting the values into the formula gives:
s² = [737 − 5(11.8)²] / (5 − 1)
= [737 − 696.2] / 4
= 40.8/4
s² =10.2
Therefore, the sample variance, s² = 10.2
Observe. The two methods are correct and arrive at the same answer. Method 2 is shorter and more straightforward compared to method 1. Therefore, it is upon you to choose one that seems easier for you.
Note: You should use the sample variance when:
- The data represent a subset of a larger population.
- You want to make inferences about the larger population.
- The population variance is unknown.
- Your dataset comes from a sample rather than a complete population.
Sample Variance vs Population Variance
Both the sample variance and population variance are measures of dispersion (variability). While the population variance measures the actual variability based on all data values in the population, the sample variance measures the variability within the population using a subset of the population called a sample.
The main difference between sample variance and population variance lies in the formula. Specifically, while the sum of squared deviations in the population variance formula is divided by the population size, N, the sum of squared deviations in the sample variance formula is divided by n-1, where n is the sample size. Dividing by n − 1 helps correct the bias that can occur when using sample data to estimate population variance.
The table below provides a quick summary of the key differences between the sample and population variance.
| Feature | Sample Variance | Population Variance |
|---|---|---|
| Symbol | s² | σ² |
| Data used | A sample from a larger population | The entire population |
| Mean used | Sample mean, x̄ | Population mean, μ |
| Denominator | n − 1 | N |
| Purpose | Estimate population spread | Describe the actual population spread |
Relationship Between Variance and Standard Deviation
Variance and standard deviation are closely related measures of dispersion. While the variance measures the average squared distance from the mean, the standard deviation is the square root of the variance.
In other words, Standard deviation = √variance
Frequently Asked Questions
This variance calculator finds the sample variance or population variance of a dataset. It also shows you how to find the variance for your dataset manually, using a step-by-step approach.
Choose Sample Variance if your data values are a sample from a larger population or Population Variance if your data values represent the entire group you want to study.
The sample variance formula is: s² = Σ(xi − x̄)² / (n − 1), where s² is the sample variance, x̄ is the sample mean, xi is each data value, and n is the sample size.
The population variance formula is: σ² = Σ(xi − μ)² / N, where σ² is the population variance, μ is the population mean, xi is each data value, and N is the population size.
Sample variance uses n − 1 because sample data are used to estimate the spread of a larger population. Dividing by n − 1 helps correct the bias that can occur when estimating population variance from a sample.
Standard deviation is the square root of variance. For example, if the variance is 25, the standard deviation is √25 = 5.
