Relate › Correlation

Partial correlation

Partial correlation measures the Pearson or Spearman association between X and Y after linearly removing one or more control variables Z — the bivariate analogue of a partial regression slope.

What is Partial correlation?

Partial correlation answers: 'how related are X and Y once their shared dependence on Z is removed?'. Mechanically, regress X on Z, regress Y on Z, and correlate the residuals. The result is the strength of the X-Y association that's not explained by Z.

Same role as the partial slope in multiple_linear_regression. Use partial correlation when the question is symmetric (no clear outcome / predictor split); use regression when you want effect-size + CI on a directional model.

When should I use Partial correlation?

  • Confounding control in a bivariate analysis.
  • Mediation hypothesis screening (X and Y might be related only through Z).
  • When you want a single Z-adjusted correlation coefficient rather than a regression slope.

What data does it need?

X, Y, and ≥ 1 control column(s) Z.

What does it report?

Partial r, t with df adjusted for the number of controls, p, Fisher-z CI.

What does it assume?

  • Same as Pearson (linearity + bivariate normality of residuals) or Spearman (monotonicity).
  • Z's effect on X and Y is correctly modelled as linear in the parametric (Pearson) version.

How do I interpret the result?

Partial r ≈ raw r ⇒ Z doesn't confound the X-Y relationship.

Partial r ≪ raw r ⇒ Z explains most of the apparent relationship.

See also