Analyze · Correlation

Correlation Matrix

Compute the pairwise correlation matrix (Pearson, Spearman, or Kendall) for two or more numeric variables, with p-values, significance stars, Fisher-z confidence intervals (Pearson), and a heatmap.

In the menus Analyze › Correlation › Correlation Matrix

Also searched as correlation correlations pearson pearson correlation spearman spearman rank correlation kendall kendall tau

When to use it

Explore how several numeric variables move together (which pairs are positively or negatively associated, and how strongly) before modeling, or to screen for multicollinearity.

When not to: When the relationship is expected to be curved rather than monotonic (Pearson and Spearman will both understate or miss it; look at the scatter plot instead), when you need to control for a third variable's influence (use partial correlation), or when you intend to interpret any correlation causally without a design that supports that claim.

Step by step

  1. Open it from the menu

    Click Analyze in the menu bar; under Correlation choose Correlation Matrix.

  2. Fill in the form

    Choose the columns: Columns to relate. The form lists only columns whose type fits each field.

  3. Check the options

    The options start at their defaults: Kind of correlation, Rows with blanks. Change one only when your question needs it.

  4. Run the analysis

    Press Run analysis. The Result Card opens on its Results tab.

What to choose in the form

Fields of the Correlation Matrix form
Columns to relate Variables requiredOne numeric column. Two or more number columns. Each pair gets a correlation.
Kind of correlation MethodPearson measures straight-line relationships; Spearman and Kendall's tau use ranks, so any steady rise or fall counts. Not sure? Keep Pearson (straight-line), then look at the scatter plots; choose Spearman if they curve or have outliers.
Rows with blanks Missing-value handlingpairwise: each pair uses every row where both have values. listwise: only rows complete in all chosen columns. Not sure? Keep pairwise. It uses the most rows for each pair.

How to read the card

The Results tab starts with what to know first (rows left out, checks that did not pass), then the interpretation in words and the Key Results; charts and assumption checks follow further down. Learn More explains the method in plain words. Read a Result Card covers all four tabs.

What it assumes

Normality (of residuals, not of the raw data)

If it does not hold: Pearson's r and its p-value assume the two variables are approximately normal; strong non-normality (skew, heavy tails, outliers) distorts the p-value and the confidence interval around r more than it distorts r itself.

How to check: Shapiro-Wilk per variable (for 3 to 5000 observations), reported on the card only when Pearson's method is used; Spearman and Kendall do not require it and the card does not run this check for them.

Linearity

If it does not hold: Pearson's r captures only straight-line association; a strong curved (nonlinear) relationship can produce a small or even zero Pearson r despite the variables being clearly related, understating the true association.

How to check: For Pearson only, the card's 'Linearity (quadratic-term check) & outliers' row refits every pair with an added squared term (in both directions) and flags curvature when the squared term adds at least 2% explained variance with p < .01 on a partial F-test (pairs with fewer than 10 complete cases are skipped); the same row counts 1.5 x IQR outliers per variable. A curve that a squared term does not capture (a step or an S-shape) can still pass, so inspect the scatterplot directly.

A worked example

Pearson correlations among bill length, bill depth, flipper length, and body mass across 342 penguins.

Result: Flipper length and body mass correlate at r = 0.87, 95% CI [0.84, 0.89], p < .001; bill length and bill depth correlate at r = -0.23, p < .001.

Flipper length and body mass move together very strongly and consistently: larger-flippered penguins are reliably heavier. The bill length/depth correlation is real (a large sample makes even a modest r statistically significant) but weak in practical terms, and its negative sign is driven by species differences in bill shape, worth checking with a scatter plot colored by species before reading too much into the pooled number.

From the Statistics Library.

The code tabs

Code gives this analysis as Python, R and MATLAB code (and SAS where the tab offers it), reading the data the way KernelStats did. Export sends the card to a report or to slides. See The Code tab.

Understand the statistics

Ask Oobi

Type one of these into Ask Oobi beside your data:

  • Across the penguins, which body measurements are most strongly correlated: does a longer bill go with longer flippers?
  • Explain the correlation matrix in plain words.
  • What does r-squared mean?

Last reviewed November 16, 2026.

Report an unclear step