Using the Coefficient of Determination Calculator (R²)
The coefficient of determination, written R², tells you how much of the variation in a dependent variable (Y) is explained by an independent variable (X) through a fitted model. This calculator takes your paired data, fits the ordinary least-squares regression line, and reports R² along with the slope, intercept, and Pearson correlation. Paste two equal-length lists of numbers, press Calculate, and you get the full picture of how well a straight line describes the relationship.
The formula
R² is defined as the fraction of total variance in Y that the model accounts for:
R² = 1 − (SSres / SStot)
- SStot = Σ(yᵢ − ȳ)² — the total sum of squares, the variance of Y around its own mean ȳ.
- SSres = Σ(yᵢ − ŷᵢ)² — the residual sum of squares, the variance left over after the model's predictions ŷᵢ.
For simple linear regression the best-fit line has slope b = Σ(xᵢ−x̄)(yᵢ−ȳ) / Σ(xᵢ−x̄)² and intercept a = ȳ − b·x̄. In that one-predictor case, R² is exactly the square of the Pearson correlation coefficient r, which is why R² is always between 0 and 1 for a least-squares fit.
How to read the result
R² is a proportion, so multiply by 100 to get a percentage. R² = 0.85 means the regression line explains 85% of the variance in Y, and 15% remains unexplained (measurement noise, omitted variables, or nonlinearity). R² = 0 means the line does no better than simply predicting the mean of Y every time; R² = 1 means every data point falls exactly on the line.
Common reference points
- R² = 1.00 — a perfect fit; all points are collinear.
- R² ≈ 0.90+ — a very strong relationship, common in controlled physics or engineering data.
- R² ≈ 0.25–0.50 — typical in social-science and behavioral data, where many factors drive the outcome.
- R² ≈ 0 — no linear relationship; note that a curved (e.g. parabolic) relationship can still give R² near 0 for a straight line.
Frequently Asked Questions
What does the coefficient of determination (R²) measure?
How is R² related to the correlation coefficient r?
Can R² be negative?
Does a high R² mean the model is correct?
Common Tip Percentages
| Service | Typical Tip Range | Notes |
|---|---|---|
| Restaurant (sit-down) | 15–20% | 20%+ for exceptional service |
| Food delivery | 10–20% | Consider extra for long distances |
| Taxi / rideshare | 10–20% | More for assistance with luggage |
| Hotel housekeeping | $2–5/night | Leave daily, not just at checkout |
| Barber / hair salon | 15–20% | On pre-discount total |
| Pizza delivery | 10–15% or $3–5 minimum | Higher in bad weather |
General Household Budget Ratios (50/30/20 Rule)
| Category | % of Net Income | Examples |
|---|---|---|
| Needs | 50% | Rent, groceries, utilities, insurance |
| Wants | 30% | Dining out, entertainment, hobbies |
| Savings / Debt | 20% | Emergency fund, retirement, extra payments |
Common Measurement Conversions for Everyday Use
| Quantity | US / Imperial | Metric Equivalent |
|---|---|---|
| 1 cup | 8 fl oz | 237 mL |
| 1 pint | 16 fl oz | 473 mL |
| 1 quart | 32 fl oz | 946 mL |
| 1 gallon | 128 fl oz | 3.785 L |
| 1 lb | 16 oz | 453.6 g |
| 1 ft | 12 in | 30.48 cm |