Residual Error Calculator

Compare actual and predicted values, inspect residual patterns, detect outliers, measure model bias, and export detailed machine learning error analysis instantly online with confidence.

Enter prediction data

Use the row editor, paste lists, or upload a CSV file. Blank rows are ignored.

Used for residual standard error.
LabelActualPredictedWeightLeverageRemove
Bulk paste lists

Separate numbers with spaces, commas, semicolons, or line breaks. Labels use one line per observation.

Columns: actual, predicted, weight, leverage, label.

Formula used

Residual: ei = yi − ŷi

MAE: Σ|ei| ÷ n

MSE: Σei2 ÷ n

RMSE: √MSE

Residual standard error: √[SSE ÷ (n − p)]

Studentized residual: ei ÷ [RSE√(1 − hii)]

A positive residual means the model predicted too low. A negative residual means the model predicted too high. A zero residual represents an exact prediction match.

How to use this calculator

  1. Select standard, weighted, or diagnostic analysis.
  2. Enter actual and predicted values for each observation.
  3. Add optional weights, leverage values, and labels.
  4. Choose outlier, tolerance, precision, and sorting settings.
  5. Press calculate to view metrics, tables, and charts.
  6. Copy results or export them as CSV or PDF.

Example data

LabelActualPredictedWeightLeverage
Sample A12.011.41.00.10
Sample B18.519.21.30.12
Sample C25.023.80.80.08
Sample D32.035.51.50.18
Sample E41.040.21.00.11

Residual interpretation guide

PatternPossible meaningSuggested check
Residuals centred near zeroLimited overall prediction biasInspect spread and outliers
Mostly positive residualsSystematic underpredictionReview intercept and calibration
Mostly negative residualsSystematic overpredictionReview target scaling
Funnel-shaped spreadPossible heteroscedasticityTransform targets or model variance
Curved residual patternPossible missing nonlinearityAdd features or nonlinear terms
Large isolated residualPotential outlier or data issueValidate the observation carefully

Frequently asked questions

What is a residual error?

A residual is actual value minus predicted value. It measures one prediction error. Its sign shows prediction direction.

Why can residuals be positive or negative?

Positive values indicate model underprediction. Negative values indicate model overprediction. Zero means both values match.

What is the difference between residual and absolute residual?

A residual preserves the error direction. An absolute residual removes the sign. Absolute values support MAE calculations.

How does RMSE differ from MAE?

RMSE squares errors before averaging them. Large errors receive greater influence. MAE treats errors more evenly.

When should I use weighted residuals?

Use weights when observations have different importance. Larger weights increase an observation’s influence. Weights must remain positive.

What is a standardized residual?

It divides each residual by residual spread. This creates a scale-free comparison. Large magnitudes may identify unusual predictions.

What is a studentized residual?

It adjusts residuals using leverage and model error. Regression diagnostics often use it. Leverage values must stay below one.

Can percentage residual be calculated when actual equals zero?

No reliable percentage exists with a zero denominator. The calculator displays unavailable instead. Other error measures remain valid.

Does a low mean residual guarantee a good model?

No, positive and negative errors may cancel. Review MAE, RMSE, charts, and outliers. Multiple diagnostics provide stronger evidence.

Related Calculators

Linear Regression CalculatorPolynomial Regression CalculatorRidge Regression CalculatorLasso Regression CalculatorElastic Net Regression CalculatorLogistic Regression CalculatorRegression Coefficient CalculatorRegression Prediction CalculatorMean Squared Error CalculatorMean Absolute Error Calculator

Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.