Residual Calculator
Enter the observed and predicted values to compute the residual.
Result
How it is calculated
For one data point the tool computes three numbers. Residual: e = observed − predicted, so a negative value means the model overshot. Absolute residual: |e|. Percent residual: e ÷ observed × 100, measured against the observed value, not against the prediction. The first two are shown with two decimals, the percentage rounded to two decimals as well. If observed is exactly 0 the percentage cannot be computed and the tool prints n/a instead. When the observed value is negative, dividing by it flips the sign of the percentage, so read it together with the plain residual. Units of the first two numbers are those of your data.
Worked example
A model predicts 52.5 for a data point whose observed value is 48. Residual: 48 − 52.5 = -4.50. Absolute residual: |−4.50| = 4.50. Percent residual: −4.5 ÷ 48 = −0.09375, times 100 = −9.375, shown as -9.38%. The negative sign says the model predicted too high by 4.5 units, which is about 9.4% of the observed value. Had the observed value been 0 with the same prediction, the percentage line would show n/a.
Common mistakes
- Subtracting in the wrong order: the tool uses observed minus predicted, so predicted minus observed flips every sign and a negative residual here means the model overestimated.
- Dividing by the prediction to get the percent: this tool divides by the observed value, so the percentage differs from the one you get with the predicted value as the base.
- Averaging signed residuals and concluding the fit is perfect: positive and negative residuals cancel, so use the absolute values when judging the size of the errors.
- Trusting the percent residual when observed is close to zero: the percentage becomes huge and unstable, and is n/a at exactly 0.
- Entering a fitted value from a rounded model output: residuals are small differences, so rounding the prediction first can change their sign or size.
About this calculator
In regression and statistical modeling, a residual is the difference between what was actually observed and what a model predicted: residual = observed − predicted. This calculator also computes the absolute residual (its magnitude regardless of sign) and the percent residual (the residual as a percentage of the observed value), giving three views of the same gap in fit.
Statistics students, data analysts and researchers examine residuals to judge how well a regression line or model fits the data — plotting residuals against predicted values (a residual plot) reveals patterns a simple R² can hide, such as heteroscedasticity (residual spread growing with the predicted value) or nonlinearity (a curved pattern indicating a linear model is the wrong choice). A residual's sign also matters directly: a positive residual means the model underestimated that observation, a negative one means it overestimated it.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm’s Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments