1001Ferramentas
🔗Calculators

Pearson Correlation Calculator

Calculate the Pearson correlation coefficient (r) between two data sets and measure the strength of the linear relationship, from -1 to +1.

r

Pearson correlation coefficient (r)

Pearson's r tells you how strong a linear relationship between two variables is, and which way it leans: r = Σ((xᵢ−x̄)(yᵢ−ȳ)) / √(Σ(xᵢ−x̄)²·Σ(yᵢ−ȳ)²). The value always sits in [−1, 1], and its square tells you what fraction of the variance in Y the X variable accounts for. Take X=[1,2,3,4,5] and Y=[2,4,5,4,6]: you get r ≈ 0.83, meaning roughly 69% of Y's variance is explained linearly by X. Watch out for outliers, though. One extreme point is enough to flip the sign, as Anscombe's quartet (1973) famously demonstrated. When the data is monotonic but not linear, or sits on an ordinal scale, reach for Spearman's ρ instead.

Applications

It shows up in linear regression diagnostics, in finance (the Sharpe ratio, Markowitz portfolio diversification built on asset correlation matrices), in epidemiology for dose-response studies, in social science work on test-retest reliability, in machine learning feature selection, and on the factory floor for quality control.

FAQ

Does r = 0 mean independence? Not at all. It only rules out a linear link. Y = X² over a symmetric range gives r ≈ 0 even though the relationship is perfectly deterministic.

Minimum sample size? The math works from n ≥ 3, but you usually want n ≥ 30 before trusting any inference. Below that, r bounces around a lot.

Pearson or Spearman? Pearson expects linearity and roughly normal continuous data. Spearman makes no such assumptions, so it tends to win out when you have outliers, ranked data, or monotonic patterns that aren't straight lines.

Related Tools

📈

Point-Biserial Correlation

Computes the point-biserial correlation coefficient, which measures the association between a continuous variable and a dichotomous (two-group) variable. It is, in fact, the Pearson correlation applied to the case where one variable takes only two values — so it ranges from −1 to +1 and carries the same interpretation. It shows up often in psychometrics, to assess how well a test item (right/wrong) discriminates between high- and low-scoring students. Enter the continuous values of each of the two groups.

🔗

Pearson Spearman Correlation Calculator

Computes simultaneously Pearson product moment correlation and Spearman rank correlation coefficients between two variables.

🔗

Correlation Significance Test

Computes the significance test for the Pearson correlation coefficient, answering whether the observed correlation between two variables is real or could have arisen by chance. A correlation of 0.5 in a sample of 6 points is unimpressive; the same correlation in 600 points is very strong. The test converts r into a t value, with n−2 degrees of freedom, and returns the p-value. The tool computes r, the t statistic and the two-sided p-value. Enter the two series of paired values.

📊

Pearson Correlation Coefficient

Compute Pearson correlation coefficient r between X and Y lists.

📈

CI for Correlation (Fisher z Transform)

Computes the confidence interval for a correlation coefficient using the Fisher z transformation. The sampling distribution of r is skewed, especially near −1 or +1, which prevents applying the usual symmetric margin. Fisher solved this with a transformation that makes the distribution approximately normal; you build the interval on that scale and then map back to r. The result is an asymmetric interval, narrower on the side near the extremes. Enter the coefficient r and the sample size.

📉

Linear Regression OLS Calculator

Computes simple linear regression coefficients by ordinary least squares method from a list of x y data pairs.

The results provided by this tool are for general informational and educational purposes only and do not constitute professional, financial, medical, legal, tax or accounting advice. Always confirm important decisions with a qualified professional and official sources.