Pearson Correlation (linear association)

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 strength and direction of the LINEAR relationship between two continuous (interval/ratio) variables measured on the same cases.

Reports r, 95% CI (Fisher-z), t-statistic, p-value, and r². Pearson's r is interpreted on a [-1, +1] scale: 0 = no linear association, ±1 = perfect linear association. Sensitive to outliers and assumes a roughly linear, homoscedastic, bivariate-normal relationship.

Worked example

Is weekly study time related to exam performance?

For 80 students, weekly study hours and final-exam score (0–100) were recorded; Pearson's r measures the strength of the straight-line relationship.

Result

Study time and exam score were positively correlated, r(78) = .53, p < .001 — study time accounted for about 28% of the variance in scores (r² = .28).

How you'd report it (APA)

A Pearson correlation showed a significant positive relationship between study time and exam score, r(78) = .53, p < .001.

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

When to use it

  • Cross-sectional bivariate continuous (one-time measurement)
    A nutritionist measures daily caloric intake and BMI in 200 adults at a single clinic visit.
  • Test-retest reliability (same DV at two time points)
    A clinical psychologist administers the Beck Depression Inventory to 80 patients at intake and again 4 weeks later.
  • Two parallel measurements on the same unit
    A lab compares HbA1c measured by a new finger-prick assay against the venous-blood reference assay in 60 patients.
  • Pre-regression screening of continuous predictors
    An economist is building a model of household savings rate from income, age, education-years, household size, and interest rate.

When NOT to — use instead

Hypotheses

H₀: ρ = 0 — there is no LINEAR association between x and y in the population.
Hₐ: ρ ≠ 0 — there is a non-zero linear association (two-sided default).

Parameter tested: population Pearson correlation ρ

Assumptions (and what to do if they fail)

Both variables are approximately normally distributed — strictly, the pair (X, Y) is bivariate normal.medium

Check: Shapiro-Wilk p on x and y separately.

If violated: Non-normal marginals make the Pearson r's sampling distribution unreliable for CIs and p-values in small samples.

No extreme bivariate outliers that could unduly influence r.high

Check: Count cases with Mahalanobis D² > 7.38.

If violated: A single influential point can dramatically inflate or attenuate r.

Constant variance of y across the range of x (residuals show no funnel / fan pattern).medium

Check: Visual: residuals vs fitted scatter should show random scatter (no funnel).

If violated: Heteroscedasticity doesn't bias r but inflates its standard error — CI coverage and p-value accuracy suffer.

Ready to run a Pearson Correlation (linear association) on your own data?

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

Run this test →