Partial Correlation (linear, controlling for covariates)

Verified

Advanced & specialized

Independently verified. Every statistic this test reports has been re-derived against an independent reference — never the library the pipeline itself calls — the rendered output was read back in a browser, and the result is locked with a committed regression suite.

Run this test straight away on a free built-in teaching dataset — no data of your own needed — or bring your own. Either opens the guided workspace: variable setup, assumption diagnostics, results with effect sizes and confidence intervals, figures, and APA-ready reporting.

Loading teaching datasets…

Or use your own dataset

Loading your datasets…

Measures the LINEAR association between two continuous variables x and y after linearly removing the effect of one or more covariates z from both.

Answers the question: 'What is the relationship between x and y for cases equated on z?' Reports partial r, Fisher-z 95% CI, t, p, partial r², and the zero-order (unadjusted) r for comparison — when partial and zero-order r diverge substantially, the data exhibit a confounding (or suppression) pattern.

Worked example

Do ice-cream sales relate to drownings once temperature is controlled?

Across 100 days, ice-cream sales, drownings and temperature were recorded. A partial correlation removes temperature to test the direct sales–drownings link.

Result

The zero-order correlation (r = .58) vanished once temperature was partialled out, r = .03, p = .78 — the association was entirely confounded by heat.

How you'd report it (APA)

After controlling for temperature, the partial correlation between ice-cream sales and drownings was non-significant, r = .03, p = .78 (zero-order r = .58).

Try it yourself: Load this ready-made sample and follow the run above.

When to use it

  • Confounder removal — controlling for a known third variable
    An economist observes a strong positive Pearson r between ice-cream sales and drowning deaths across US cities.
  • Multiple-covariate adjustment
    A psychologist measures impulsivity, risk-taking, and controls for age, sex, and IQ in 250 adolescents.
  • Suppressor variable detection
    A workplace researcher finds zero zero-order r between training hours and job performance.

When NOT to — use instead

Hypotheses

H₀: ρ_{xy·z} = 0 — after controlling for z, there is NO linear association between x and y.
Hₐ: ρ_{xy·z} ≠ 0 — a non-zero partial linear association remains (two-sided default).

Parameter tested: population partial correlation ρ_{xy·z}

Assumptions (and what to do if they fail)

Residuals of x|z and y|z are approximately normal.medium

Check: Shapiro-Wilk on e_x and e_y.

If violated: Non-normal residuals make p-values / CI for small-n partial r unreliable.

Residuals e_x and e_y show constant variance (no funnel).medium

Check: Breusch-Pagan p on e_y ~ e_x.

If violated: Heteroscedasticity inflates SE of the partial r; CI coverage and p-value accuracy suffer.

No high-leverage / high-influence cases that dominate the partial fit.high

Check: Count Mahalanobis-extreme cases in the residual space.

If violated: A single influential case can dramatically inflate or attenuate the partial r.

Ready to run a Partial Correlation (linear, controlling for covariates) on your own data?

Guided setup, automatic assumption checks, effect sizes, figures and an APA write-up.

Run this test →