Mean Squared Log Error Calculator

Analyze model predictions through logged error comparisons. Use manual fields or bulk text for evaluation. Download polished outputs for sharing, audits, and repeat checks.

Enter actual and predicted values

Use commas, spaces, tabs, or new lines. MSLE only accepts nonnegative values because it uses ln(1 + value).

Input tips
  • Keep actual and predicted lists the same length.
  • Zeros are allowed, but negatives are not.
  • Paste values from spreadsheets directly.

Example data table

This sample produces an MSLE near 0.013888 and an RMSLE near 0.117848.

# Actual Predicted ln(1 + actual) ln(1 + predicted) Squared log error
132.51.3862941.2527630.017831
2561.7917591.9459100.023762
31092.3978952.3025850.009084
420183.0445222.9444390.010017
550553.9318264.0253520.008747

Formula used

MSLE = (1 / n) × Σ [ ln(1 + predictedᵢ) − ln(1 + actualᵢ) ]²
RMSLE = √MSLE

MSLE emphasizes relative differences after logarithmic transformation. Large errors on large targets are softened, while proportional mistakes remain visible.

How to use this calculator

  1. Paste actual values into the first box.
  2. Paste matching predicted values into the second box.
  3. Add a dataset label, rounding preference, and tolerance.
  4. Press Calculate MSLE to generate metrics, tables, and the graph.
  5. Use the CSV or PDF buttons to export your evaluation results.

Frequently asked questions

1. What does MSLE measure?

MSLE measures average squared differences between logged actual and predicted values. It rewards models that keep proportional errors small instead of only minimizing raw distance.

2. When is MSLE useful in machine learning?

MSLE is useful when targets span wide ranges and relative accuracy matters. It often fits forecasting, demand estimation, traffic prediction, and revenue modeling tasks.

3. Can I use zero values?

Yes. The formula uses ln(1 + value), so zeros are valid inputs. Negative values are not valid because logarithms of negative shifted values break the metric.

4. Why does the calculator reject negative numbers?

MSLE depends on logarithms. If actual or predicted values are negative, ln(1 + value) may be undefined or distort interpretation, so the calculator blocks them.

5. What is the difference between MSLE and RMSLE?

MSLE is the averaged squared logged error. RMSLE is its square root. RMSLE stays in logged units and can feel easier to read when comparing model runs.

6. Does a lower MSLE always mean a better model?

Lower MSLE usually indicates better relative fit for the same dataset. It should still be reviewed alongside business goals, bias direction, and other validation metrics.

7. Why include a correlation value here?

Correlation does not replace MSLE, but it helps show directional alignment between actual and predicted values. High correlation with high MSLE can still reveal calibration problems.

8. Can I paste spreadsheet columns directly?

Yes. The parser accepts commas, spaces, tabs, and line breaks. You can usually paste a full spreadsheet column into each box without reformatting.

Related Calculators

mean bias error calculatorarea under pr curvematthews correlation coefficient calculatorkolmogorov smirnov statistic 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.