Scatter Plot Calculator
This scatter plot calculator will allow you to visualize any set of 2D data points.
Line of best fity = 1.99x + 0.05
Slope1.99
y-intercept0.05
Correlation r0.99865176strong linear relationship
R²0.9973053399.73% of the variation explained
Points5
Fit and residuals
| x | y | Predicted | Residual |
|---|---|---|---|
| 1 | 2.1 | 2.04 | 0.06 |
| 2 | 3.9 | 4.03 | -0.13 |
| 3 | 6.2 | 6.02 | 0.18 |
| 4 | 7.8 | 8.01 | -0.21 |
| 5 | 10.1 | 10 | 0.1 |
The formula
least squares: minimise the sum of squared residuals
What least squares minimises
The fitted line is the one making the sum of squared vertical distances as small as possible. Squaring means large misses count disproportionately, which is why a single outlier can drag the line noticeably.
R² is the share of the variation in y that the line accounts for. A high R² says the line fits; it does not say x causes y, and it does not guarantee a line was the right model.