There is no single correlation test. A correlation coefficient is a single number summarising how strongly two paired variables move together, most often in a straight line.1PubMed Central. Biostatistics Series Module 6: Correlation and Linear Regression The right one depends mostly on what kind of data your two variables are, so the same question asked of measurements, rankings, yes/no answers or categories can call for a different statistic. Most of the common methods also quietly assume the two variables rise or fall together in a straight line, which makes the shape of the pattern matter as much as the data type.
Match the Test to Your Data Types
- Two measurements, bell-shaped, straight-line pattern: Pearson’s r.2PubMed. Correlation Coefficients: Appropriate Use and Interpretation “Bell-shaped” is the everyday way of saying normally distributed: most values cluster in the middle and thin out evenly on both sides.
- Two measurements that aren’t bell-shaped, or data already in ranks: Spearman’s rho.1PubMed Central. Biostatistics Series Module 6: Correlation and Linear Regression
- One measurement and one yes/no variable: point-biserial correlation.3Laerd Statistics. Point-Biserial Correlation using SPSS Statistics
- Two rating-scale or ordered-category variables: polychoric correlation, or tetrachoric when both are yes/no.4PubMed Central. Polychoric Correlation With Ordinal Data in Nursing Research
- Two unordered category variables, such as region and product choice: Cramér’s V.5Wikipedia. Cramér’s V
- A curved or complicated relationship: distance correlation or mutual information.6Wikipedia. Distance correlation
To place each variable, ask what values it can take. Weight, time or income are measurements and can take many values. A scale like “disagree, neutral, agree” has an order but uneven gaps. Blood type or city has no order at all. A passed/failed variable has only two values.
Take hours studied and exam score: both are measurements, so start with Pearson. Hours studied and pass/fail pairs a measurement with a yes/no, which points to point-biserial. Satisfaction rating and favourite brand pairs an ordered variable with an unordered one, so one common approach is to treat both as categories and use Cramér’s V.
Some variables fit two types. A 0 to 10 satisfaction score or a count of items can be treated as a measurement or as ordered categories, depending on how many distinct values it has and how the data are spread. A rating with only a handful of points that pile up at one end is usually safer treated as ordered categories. If you’re unsure, run two defensible options and report both; that is more convincing than silently choosing one.
Before picking anything, plot the data. A scatter plot shows at once whether the pattern looks straight, curved or messy, and it reveals extreme points that could swing the result.
Pearson or Spearman for Two Measurements
Pearson’s r is the standard choice when both variables are bell-shaped.2PubMed. Correlation Coefficients: Appropriate Use and Interpretation It only captures straight-line relationships, though.7PubMed Central. Robust Correlation Analyses: False Positive and Power Validation Using a New Open Source Matlab Toolbox It is also very sensitive to outliers, meaning extreme points far from the rest, so a single outlier can give a badly misleading result.7PubMed Central. Robust Correlation Analyses: False Positive and Power Validation Using a New Open Source Matlab Toolbox
When one or both variables aren’t bell-shaped, a rank correlation like Spearman’s rho is the usual alternative.1PubMed Central. Biostatistics Series Module 6: Correlation and Linear Regression Spearman replaces each value with its position from smallest to largest, then applies Pearson’s formula to those positions. Because ranks ignore distances, one huge value can’t dominate. It still assumes the relationship moves consistently in one direction rather than curving back.1PubMed Central. Biostatistics Series Module 6: Correlation and Linear Regression Kendall’s tau is another rank option, but with tied values Spearman tends to give more trustworthy results, and Kendall gets worse as ties increase.8Animal Behaviour. Effective use of Spearman’s and Kendall’s correlation coefficients for association between two measured traits
A common mistake is using Pearson on skewed data out of habit. Income, reaction times and counts are often lopsided with a long tail, so reporting Spearman alongside is a simple way to check that the result holds.
If you spot an extreme point, first check whether it is a data entry error. If it’s genuine, report results with and without it, or use a rank or robust method that downweights it.
Both Pearson and Spearman run from -1 to +1. The sign gives the direction, and values near 0 mean little straight-line or steady pattern. Squaring Pearson’s r gives the share of the variation in one variable that moves along with the other, so an r of 0.5 corresponds to about a quarter. What counts as strong depends on the field, so judge your value against similar studies rather than a universal cutoff.
Sometimes one variable always rises as the other rises, but along a curve, such as quickly at first and then flattening. Spearman can then be close to 1 while Pearson is noticeably lower, and that gap is itself a hint that the pattern is steady but not straight. Spearman misses patterns that go up then down, so it does not fix every curve.
Rating Scales and Ordered Categories
Ordinal variables have ordered categories, like a 1 to 5 agreement scale.9The DO Loop. What is polychoric correlation? Polychoric correlation treats each rating as a rough cut of a hidden smooth scale underneath, and it estimates the correlation between those hidden scales.9The DO Loop. What is polychoric correlation? Applying Pearson directly to ratings assumes an unrealistic bell-shaped pattern.4PubMed Central. Polychoric Correlation With Ordinal Data in Nursing Research
The step from “strongly disagree” to “disagree” need not feel the same size as the step from “agree” to “strongly agree,” so the numbers 1 to 5 are labels for an order. Rank-based and polychoric methods use only the order, which is why they suit this kind of data better than Pearson.
In simulations, polychoric and polyserial correlations were more accurate than Spearman for ordered categories, even when their assumptions were broken.10Frontiers in Applied Mathematics and Statistics. Choosing the right correlation for ordinal data: practical recommendations from a simulation study Polyserial is for one ordered category and one measurement. For rating-scale research, polychoric is a strong default, with Spearman as a simpler fallback.
Polychoric isn’t on most spreadsheet menus. Statistics packages like R, SAS and Stata offer it, and survey and questionnaire research commonly uses it when building scales.
Yes-or-No and Category Variables
Point-biserial correlation measures strength and direction between one measurement and one yes/no variable.3Laerd Statistics. Point-Biserial Correlation using SPSS Statistics The sign depends on which group you coded as 1. Positive means the group coded 1 tends to have higher values, and swapping the coding flips the sign but not the strength.
For two category variables, the first step is usually a chi-square test of whether they’re linked at all.11SPSS Tutorials. Cramér’s V: What is it? It compares your observed counts with the counts expected if the variables were unrelated. It works on counts of people, not percentages or averages, so enter the raw numbers. It becomes unreliable when many cells have very small expected counts, and then categories are often combined or an exact test used.
A tiny p-value doesn’t mean a strong link; a weak link in a large sample can still give a p-value near zero.11SPSS Tutorials. Cramér’s V: What is it? So Cramér’s V is used to show how strong the link is, from 0 (none) to 1 (perfect).12rcompanion.org. Which Statistical Test Should You Use for Correlation For two yes/no variables, a measure called phi is the usual companion.12rcompanion.org. Which Statistical Test Should You Use for Correlation Because unordered categories have no “higher” or “lower,” Cramér’s V only says how strongly categories go together, and it can’t be negative.
Cramér’s V gives one number for the whole table, but it does not say which categories drive the link. To find that, look at the table of counts or percentages by row and see where the biggest differences lie.
Curved and Complicated Relationships
Distance correlation measures both straight-line and curved association, unlike Pearson.6Wikipedia. Distance correlation It has proved effective at finding curved links in fields like gene research.13PubMed Central. Inferring Nonlinear Gene Regulatory Networks from Gene Expression Data Based on Distance Correlation Mutual information captures every type of dependence and is zero only when variables are fully unrelated.14PubMed Central. Mutual information: Measuring nonlinear dependence in longitudinal epidemiological data It works the same way for numbers and categories.14PubMed Central. Mutual information: Measuring nonlinear dependence in longitudinal epidemiological data For a straight-line relationship between bell-shaped variables, it can be converted directly to the same information as Pearson.15SoftwareX. ennemi: Non-linear correlation detection with mutual information
A U-shape, like performance rising then falling with stress, can give Pearson near zero, which would wrongly suggest no link. A scatter plot reveals the curve immediately.
Distance correlation runs from 0 to 1, with 0 meaning the variables are unrelated and larger values meaning a stronger link of any shape. Because it has no negative values, you need a scatter plot to see whether the link rises, falls or curves. It is for two measurements, so it is not a choice for category data.
Distance correlation and mutual information are also less familiar to reviewers, so explain them briefly. Free tools such as Python packages compute them.
Correlation When You Measure the Same Thing Twice or Control for Others
Intraclass correlation assesses how consistent two or more measurements of the same thing are, such as two raters or repeat tests.16PubMed. A critical discussion of intraclass correlation coefficients It’s the usual choice for reliability questions, not Pearson. Pearson can be high even when one rater always scores 10 points higher, while intraclass correlation penalises that systematic gap.
It comes in several versions, depending on whether the same raters scored everyone and whether you want agreement on exact scores or just consistency. Choose the version that matches your design, and name it in your report, because the versions can give different numbers. Values near 1 show high reliability, and values near 0 show that differences between raters swamp differences between subjects.
Partial and semi-partial correlations show the link between two variables while removing the influence of others.17PubMed. An empirical investigation of partial effect sizes in meta-analysis of correlational data Ice cream sales and drownings both rise with temperature, and controlling for temperature removes most of that link. Partial correlation does this adjustment in one number.
Partial correlation removes the third variable’s influence from both of the variables you are comparing. Semi-partial correlation removes it from only one of them, which suits questions about what a predictor adds beyond the others. Semi-partial values are never larger in size than the matching partial values, so do not mix the two up when reporting.
Reading the Result Without Being Misled
A p-value tells you how unlikely the result would be if there were no link, but nothing about how large or important the link is.18PubMed Central. Statistical Significance Versus Clinical Importance of Observed Effect Sizes: What Do P Values and Confidence Intervals Really Represent? With thousands of cases, a tiny correlation like 0.05 can produce a very small p-value even though it explains almost none of the variation. With a small sample, a moderate correlation can fail to reach significance even though it may be real.
With small samples, the correlation you calculate is unstable and its likely range is very wide.19Charles Holbert. Sample Size Determination for Correlation Studies You need more data to detect a weaker correlation or to pin it down more precisely.20Restorative Dentistry & Endodontics. An elaboration on sample size determination for correlations based on effect sizes and confidence interval width: a guide for researchers For the same target, Spearman needs a larger sample than Pearson.20Restorative Dentistry & Endodontics. An elaboration on sample size determination for correlations based on effect sizes and confidence interval width: a guide for researchers
A confidence interval gives a range of values for the true correlation that fit your data. A result such as r = 0.30 with an interval from 0.02 to 0.54 shows the data fit anything from almost no link to a fairly strong one. Wide intervals are the honest signal that the sample is too small to pin the value down.
Two things that both rise or fall over time can show a very high correlation with no real connection.21CASRAI. Spurious Correlation: Causes & Detection In data collected over time, errors linked from one period to the next can seriously distort results.22General Linear Model Journal. Addressing Autocorrelation in Time Series Data: A Comparison of Four Analytic Methods Using Data from College Course Evaluations And when the spread of one variable changes across the range of the other, the usual significance test can flag a link mainly because of that uneven spread.23PubMed. Inferences about correlations when there is heteroscedasticity A significant result then says little about strength.24Journal of Modern Applied Statistical Methods. Inferences About the Skipped Correlation Coefficient: Dealing with Heteroscedasticity and Non-Normality Only study design, not the coefficient, can support a claim of cause.
Before you report, run through these checks:
- Look at the scatter plot for curves and extreme points.
- Confirm the test matches both variable types.
- Report the coefficient with its confidence interval, not just the p-value.
- Note the sample size and whether the data were collected over time.

