Correlation
Correlation measures the strength and direction of the linear relationship between two variables. The Pearson correlation coefficient (r) ranges from -1 to +1:
- r = +1: perfect positive linear relationship — as X increases, Y increases proportionally.
- r = 0: no linear relationship.
- r = -1: perfect negative linear relationship — as X increases, Y decreases proportionally.
Correlation is symmetric: the correlation between X and Y is identical to the correlation between Y and X. Neither variable is treated as the predictor or the outcome. Correlation tells you nothing about the slope of the relationship — only how consistently the two variables move together.
Key point: Correlation does not imply causation. A high r value between two variables may reflect a common underlying cause, a coincidence, or confounding — not a direct causal relationship.
Linear Regression
Linear regression fits the equation Y = a + bX to the data, where b is the slope (change in Y per unit change in X) and a is the Y-intercept. Regression is used when:
- You want to predict Y given a specific value of X.
- You want to quantify how much Y changes for each unit change in X.
- X is an explanatory variable (e.g., dose, time, age) and Y is the outcome.
Regression is asymmetric: the regression of Y on X gives a different line than the regression of X on Y. The choice of which variable is X and which is Y must be based on your scientific question, not statistical convention.
R² (the square of the Pearson r) appears in both correlation and regression output. In regression, R² represents the proportion of variance in Y explained by X. An R² of 0.80 means that 80% of the variability in Y is accounted for by the linear relationship with X.
Side-by-Side Comparison
| Aspect | Correlation | Linear Regression |
|---|---|---|
| Purpose | Measure strength and direction of relationship | Predict Y from X; describe relationship as an equation |
| Output | Correlation coefficient r (and R²) | Slope, intercept, confidence intervals, R² |
| Range | r ranges from -1 to +1 | Slope has units of Y per unit of X; no fixed range |
| Directionality | Symmetric: r(X,Y) = r(Y,X) | Asymmetric: regression of Y on X ≠ regression of X on Y |
| Causation implied? | No — only association | No — but frames X as the explanatory variable |
| Use when | You want to know how closely two variables move together | You want to predict Y or understand how Y changes per unit change in X |
When to Use Each in Prism
Use Correlation (Analyze → Linear regression and correlation → Correlation)
When you want to know whether two variables are associated, without designating one as the outcome. Example: are height and weight correlated in your study population?
Use Linear Regression (Analyze → Linear regression and correlation → Simple linear regression)
When you want to fit a line to predict Y from X and quantify the slope. Example: how much does enzyme activity increase per degree of temperature increase?