Lesson 10 — Correlations

What goes up
must go…

Measuring how two continuous variables move together — and why that doesn’t mean one causes the other.

What is a correlation?

The Pearson correlation test measures the strength and direction of the linear relationship between two continuous variables.

💧Variable 1Water consumed (liters)
🧱Variable 2Saliva produced (liters)

Do dogs that drink more also drool more? A scatterplot and correlation test will tell us.

Scatterplots first

Before calculating, visualize. Each dog is one point: (water consumed, saliva produced).

If points trend up-right: positive correlation. Down-right: negative. Random cloud: no correlation.

Scatterplots also reveal if the relationship is linear — a requirement for Pearson’s test.

The r-value

The correlation coefficient r ranges from −1 to +1.

−1Perfect negative
−0.5Moderate negative
0No relationship
+0.5Moderate positive
+1Perfect positive

Our dogs: r = 0.8 → strong positive correlation between water intake and saliva production.

Correlation ≠ Causation!

⚠ Important!
Churches and fast food restaurants are correlated in cities — but churches don’t cause fast food restaurants. Population size causes both!

Always ask: is there a third variable (a confounder) that could explain the relationship?

Regression: the rate of change

Once we know variables are correlated, regression tells us by how much one changes when the other does.

Linear regression line
saliva = 1.21 × (water consumed) + 0.72

Every +1 liter of water → ~1.21 more liters of saliva. Now we can make predictions!

Going further

Multiple regression

Predict one outcome from many variables simultaneously.

🐕Dog ageOlder dogs may drool less
🏃Exercise timeMore exercise → more drool
💧Water intakeDirect effect on saliva
🦮BreedSome breeds drool more
1 / 7