Statistics flashcards: correlation, variance, and standard deviation

Overview

Why this post

Short question-and-answer cards for the statistics concepts in Statistics refresher. Use these to test yourself.


What is correlation r?

The correlation coefficient r quantifies the linear relationship between two variables. It is a single number ranging from -1 to +1.

  • r = 1: perfect positive correlation (linear relationship)
  • r = 0: no correlation
  • r = -1: perfect negative correlation

Example: $r = 0.8$ is the correlation between grade and study time. $r^2 = 0.64$, so 64% of the variation in grade is explained by study time.


What is variance?

Variance measures how far the values in a data set deviate from their mean.

Population variance:

$$\sigma^{2} = \frac{1}{N}\sum_{i=1}^{N}(x_i - \mu)^{2}$$

Sample variance:

$$s^{2} = \frac{1}{n-1}\sum_{i=1}^{n}(x_i - \bar{x})^{2}$$

Example with data set $\{18, 12, 15, 15\}$:

  • Mean: $\bar{x} = 15$
  • Squared deviations: $(18-15)^2=9$, $(12-15)^2=9$, $0$, $0$
  • Sum: $18$
  • Population variance: $\frac{18}{4} = 4.5$
  • Sample variance: $\frac{18}{3} = 6$

What is standard deviation?

The standard deviation is the square root of the variance. It expresses spread in the same unit as the original data.

Population standard deviation: $\sigma = \sqrt{4.5} \approx 2.12$

Sample standard deviation: $s = \sqrt{6} \approx 2.45$


Why do we square deviations?

We square deviations so that:

  • Signs do not cancel (positive and negative deviations would sum to zero otherwise).
  • Larger errors count disproportionately more.
  • The formula is mathematically smooth and aligns with the properties of the normal distribution.

If you need a measure that is less sensitive to outliers, use mean absolute deviation instead.


Why is a square never negative?

Any real number multiplied by itself gives a non-negative result.

Case Example Result
Positive $5 \times 5$ 25
Zero $0 \times 0$ 0
Negative $(-3) \times (-3)$ 9

The two minus signs cancel: $(-8) \times (-8) = 64$.

Geometric intuition: the area of a square with side $|a|$ is always non-negative, regardless of the sign of a.


What is absolute value notation?

The absolute value $|a|$ is the distance from zero. It is always non-negative.

$$|a| = \begin{cases} a & \text{if } a \ge 0 \\ -a & \text{if } a < 0 \end{cases}$$

The distance between two numbers:

$$\text{dist}(x, y) = |x - y|$$

Absolute value removes the sign without squaring, so it is used in mean absolute deviation when you want a less outlier-sensitive metric.