The Correlation Calculator measures the strength and direction of the linear relationship between two variables. It computes the Pearson correlation coefficient (r), the coefficient of determination (R-squared), and the equation of the best-fit regression line.
Enter paired data points as comma-separated (x, y) values, one pair per line. The scatter plot with regression line updates in real time, giving you an immediate visual sense of how strongly your variables are related.
Your calculations will appear here
The Pearson correlation coefficient (r) measures the strength and direction of the linear relationship between two variables. It ranges from -1 (perfect negative correlation) through 0 (no linear correlation) to +1 (perfect positive correlation). The formula divides the covariance of x and y by the product of their standard deviations.
R-squared (the coefficient of determination) is the square of the Pearson r. It represents the proportion of variance in y that is explained by the linear relationship with x. An R-squared of 0.85, for instance, means 85% of the variability in y can be predicted from x using the regression line.
The least-squares regression line y = mx + b minimises the sum of squared residuals (vertical distances from data points to the line). The slope m equals the covariance of x and y divided by the variance of x. The intercept b ensures the line passes through the point (mean of x, mean of y). Correlation and regression are related but distinct: correlation measures strength; regression provides a predictive equation.
Problema: Given data points (1,2), (2,4), (3,5), (4,4), (5,5), find the Pearson r.
Solucion: Mean x = 3, Mean y = 4. Sum of (xi - xbar)(yi - ybar) = 5. Sum of (xi - xbar)^2 = 10. Sum of (yi - ybar)^2 = 6. r = 5 / sqrt(10 * 6) = 5 / 7.746.
Respuesta: r = 0.6455 (moderate positive correlation)
Problema: Using the same data, find the equation of the regression line.
Solucion: Slope m = 5 / 10 = 0.5. Intercept b = 4 - 0.5 * 3 = 2.5.
Respuesta: y = 0.5x + 2.5
Problema: A study finds r = 0.9 between study hours and exam scores. What is R-squared?
Solucion: R-squared = 0.9^2 = 0.81.
Respuesta: R-squared = 0.81, meaning 81% of the variance in exam scores is explained by study hours
Calculate probability of events, complements, unions, and intersections. Free online probability calculator for statistics.
Calculate standard deviation, variance, mean, and more for any dataset. Supports population and sample statistics. Free online tool.
Calculate z-scores, find values from z-scores, and determine probabilities. Free online z-score calculator with bell curve visualisation.
Calculate binomial probabilities, cumulative distributions, and expected values. Free online binomial distribution calculator with bar chart.
Calculate probabilities for normal distributions. Find areas under the bell curve, percentiles, and inverse values. Free online tool.
Calculate permutations and combinations. Find nPr, nCr, factorials, and arrangements. Free online permutation and combination calculator.