Sample Mean and Sample Standard Deviation Calculator

This sample mean and sample standard deviation calculator finds x̄ and s for your data, plus the standard error and a confidence interval for the population mean.

Checks on your data

  • With n = 8 this method assumes the data are roughly bell-shaped. That cannot be proven from so few points, so look at the histogram or box plot. Plot a histogram →

Results

Sample mean x̄
24.8375
Sample standard deviation s
1.5277785
Sample variance s²
2.3341071
Standard error of the mean s/√n
0.54015127
95 % confidence interval for the population mean
23.56025 to 26.11475
margin of error ±1.27725 (t* = 2.3646, df = 7)
Degrees of freedom n − 1
7
Sample size n
8
Sum of squares Σ(x − x̄)²
16.33875
Sample values with the sample mean and ±1 s
2426mean 24.84
95 % confidence interval for the population mean
Mean: 23.56 to 26.11242526
Working table
xx − x̄(x − x̄)²
23.1-1.73753.01891
25.40.56250.316406
22.8-2.03754.15141
261.16251.35141
24.5-0.33750.113906
27.22.36255.58141
23.9-0.93750.878906
25.80.96250.926406
Show step-by-step solution
  1. Sample mean x̄ = Σx ÷ n = 24.8375.
  2. Deviations are squared and summed: Σ(x − x̄)² = 16.33875.
  3. Sample variance s² = 16.33875 ÷ (n − 1) = 16.33875 ÷ 7 = 2.3341071.
  4. Sample standard deviation s = √2.3341071 = 1.5277785.
  5. SE = s ÷ √n = 0.54015127, so the 95 % interval is x̄ ± t*·SE = 24.8375 ± 1.27725.
x̄Σx / n
s√(Σ(x−x̄)²/(n−1))
SEs/√n
dfn − 1

What Is Sample Mean and Sample Standard Deviation?

The sample mean x̄ and the sample standard deviation s are the two most common statistics for describing a sample. The sample mean is the average of the values; s measures their spread and divides the sum of squared deviations by n − 1.

Enter your sample and choose a confidence level. The calculator returns x̄, s, the sample variance, the standard error s ÷ √n and a t-based confidence interval for the population mean, together with the full working table, a dot plot and an interval chart.

The article below explains the formulas, variables, why we divide by n − 1 and answers common questions.

How to Use the Sample Mean and Sample Standard Deviation Calculator

  1. Enter your sample values.
  2. Choose a confidence level.
  3. Read x̄, s, s² and the standard error.
  4. Use the confidence interval to estimate the population mean.

Sample Mean and Sample Standard Deviation Formula

Sample mean

xˉ=∑xin\bar x=\frac{\sum x_i}{n}

Sample standard deviation

s=∑(xi−xˉ)2n−1s=\sqrt{\frac{\sum(x_i-\bar x)^2}{n-1}}

Confidence interval

xˉ±t∗sn\bar x\pm t^*\frac{s}{\sqrt n}

Sample Mean and Sample Standard Deviation Variables Explained

SymbolMeaningNotes
x̄Sample mean
sSample standard deviationdivides by n − 1
SEStandard error of the means ÷ √n
t*Critical t valuedf = n − 1

Sample Mean and Sample Standard Deviation Worked Example

For the sample 4, 8, 6, 5, 7: x̄ = 30 ÷ 5 = 6. The squared deviations are 4, 4, 0, 1, 1, which sum to 10. So s² = 10 ÷ 4 = 2.5 and s = 1.581. The standard error is 1.581 ÷ √5 = 0.707.

With the example values loaded in the calculator above, the steps are:

  1. Sample mean x̄ = Σx ÷ n = 24.8375.
  2. Deviations are squared and summed: Σ(x − x̄)² = 16.33875.
  3. Sample variance s² = 16.33875 ÷ (n − 1) = 16.33875 ÷ 7 = 2.3341071.
  4. Sample standard deviation s = √2.3341071 = 1.5277785.
  5. SE = s ÷ √n = 0.54015127, so the 95 % interval is x̄ ± t*·SE = 24.8375 ± 1.27725.

Result: Sample mean x̄ = 24.8375; Sample standard deviation s = 1.5277785; 95 % confidence interval for the population mean = 23.56025 to 26.11475.

Why divide by n − 1?

Deviations are measured from the sample mean, which sits closer to the data than the true population mean, so dividing by n would underestimate the spread. Using n − 1 (Bessel's correction) removes that bias in the variance.

Where Sample Mean and Sample Standard Deviation Is Used

Describing a sample

Reporting x̄ and s for a lab or survey.

Estimating a population mean

Using the confidence interval.

Statistics homework

Checking sample statistics by hand.

Precursor to tests

Getting the inputs for a t-test.

Common Sample Mean and Sample Standard Deviation Mistakes to Avoid

  • Use these formulas when the data are a sample, not the whole population.
  • The sample SD is not the same as the standard error.
  • Very small samples give wide confidence intervals.

Sample Mean and Sample Standard Deviation Terms and Definitions

Sample statistic
A number calculated from a sample, such as x̄ or s.
Bessel's correction
Dividing by n − 1 so the sample variance is unbiased.

Sample Mean and Sample Standard Deviation FAQs

How do I find the sample mean and sample standard deviation?

Average the values for x̄, then take the square root of the sum of squared deviations divided by n − 1.

What is the difference between s and σ?

s is calculated from a sample using n − 1; σ describes a whole population using N.

What is the sample standard deviation used for?

To describe the spread of the sample and to estimate the population spread.

What is the difference between SD and standard error?

SD measures the spread of the data; the standard error measures the uncertainty of the sample mean.

Related calculators

Last updated 2026-11-09. See our disclaimer.