What Is Standard Deviation Formula?
The standard deviation formula is s = √(Σ(x − x̄)² ÷ (n − 1)) for a sample and σ = √(Σ(x − μ)² ÷ N) for a population. The calculation has five steps: find the mean, subtract it from each value, square the results, add them, divide, and take the square root.
Enter your data and choose the sample or population formula. The calculator numbers each step with your values, shows a working table of deviations and squares, and checks the answer with the computational shortcut formula that uses Σx² and (Σx)².
The sections below give the formulas, variables, a worked example and answers about why we square deviations and when to use n − 1.
How to Use the Standard Deviation Formula Calculator
- Enter your values.
- Choose the sample or population formula.
- Follow the numbered steps.
- Check the table totals and the shortcut formula.
Standard Deviation Formula Formula
Sample standard deviation
Population standard deviation
Computational (shortcut) form
Standard Deviation Formula Variables Explained
| Symbol | Meaning | Notes |
|---|---|---|
| x̄ or μ | Mean | |
| Σ(x − x̄)² | Sum of squared deviations | |
| n − 1 or N | Divisor | sample or population |
| s or σ | Standard deviation |
Standard Deviation Formula Worked Example
For 6, 2, 3, 1, 9, 5: the mean is 26 ÷ 6 = 4.333. The deviations squared are 2.778, 5.444, 1.778, 11.111, 21.778 and 0.444, totalling 43.333. The sample variance is 43.333 ÷ 5 = 8.667 and s = 2.944.
With the example values loaded in the calculator above, the steps are:
- Step 1. Mean: x̄ = 26 ÷ 6 = 4.3333333.
- Step 2. Subtract the mean from each value and square it (see the table).
- Step 3. Add the squares: Σ(x − x̄)² = 43.333333.
- Step 4. Divide by n − 1 = 5: s² = 43.333333 ÷ 5 = 8.6666667.
- Step 5. Take the square root: s = √8.6666667 = 2.9439203.
- Check with the shortcut: (Σx² − (Σx)²/n) ÷ 5 = (156 − 112.66667) ÷ 5 = 8.6666667.
Result: Standard deviation s = 2.9439203; Variance s² = 8.6666667.
How to Read the Working
The working table follows the textbook formula. For 6, 2, 3, 1, 9, 5 the mean is 4.333, the squared deviations total 43.333, the sample variance is 43.333 ÷ 5 = 8.667 and s = 2.944.
The shortcut formula, Σx² − (Σx)² ÷ n, gives the same sum of squares from two totals. It is quicker by hand but can lose accuracy when the numbers are large and the spread is small. The calculator shows both so you can check them against each other.
Where Standard Deviation Formula Is Used
Learning the formula
See every deviation, its square and the total.
Choosing sample or population
Switch the divisor between n − 1 and n.
Shortcut check
Confirm the shortcut gives the same variance.
Homework
Check each step of a hand calculation.
Common Standard Deviation Formula Mistakes to Avoid
- The divisor is n − 1 for a sample and n for a population.
- Square the deviations before you add. Plain deviations sum to zero.
- Take the square root at the end to get the SD from the variance.
- Keep extra decimals until the final step.
Standard Deviation Formula Terms and Definitions
- Deviation
- A value minus the mean.
- Variance
- The average squared deviation; the SD squared.
Standard Deviation Formula FAQs
What is the formula for standard deviation?
s = √(Σ(x − x̄)² ÷ (n − 1)) for a sample, and σ = √(Σ(x − μ)² ÷ N) for a population.
How do I calculate standard deviation step by step?
Find the mean, subtract it from each value, square the differences, add them, divide by n − 1 or n, then take the square root.
Why do we square the deviations?
Squaring stops positive and negative deviations from cancelling and gives larger deviations more weight. It also makes the algebra of variance simple.
What is the shortcut formula?
SS = Σx² − (Σx)² ÷ n. Divide by n − 1 for the sample variance. It avoids computing each deviation.