Sample variance and standard deviation
Definition taught in Descriptive statistics, part of Data analysis
Sample variance and standard deviation
| Type | Definition |
| Taught in | Descriptive statistics |
| Part | Data analysis |
| Worked examples | 1 |
| Questions using it | 3 |
The sample variance is s^2=\frac1{n-1}\sum_{i=1}^n(x_i-\overline x)^2, and the sample standard deviation is s=\sqrt{s^2}, in the units of the data.
Examples
The ages of 299 patients
Worked example from Descriptive statistics
Question. Summarise the patients’ ages.
Solution.
mean(heart$age); median(heart$age) # 60.83 60
quantile(heart$age, c(0.25, 0.75)) # 51 70
IQR(heart$age) # 19
sd(heart$age) # 11.89
range(heart$age) # 40 95The patients are aged 40 to 95. The mean and median are close, 60.8 and 60, so the ages are roughly symmetric. The middle half lies between 51 and 70, an interquartile range of 19 years, and the standard deviation is 11.9 years. For a roughly normal sample the interquartile range is about 1.35 standard deviations; here 19/11.9=1.6, so the ages are a little flatter than normal.
Used in
- Taught in Descriptive statistics, where the derivation and examples are.
- Also used in Using R · Estimation examples
- Questions that use it (3) — Ten normal observations (answer) · Variance of a fill volume · Caffeine in a cola
- All 2 questions on Descriptive statistics
See also
Welch interval · Sample quantile · Interquartile range · Five-number summary and boxplot · Normal quantile plot