> ## Documentation Index
> Fetch the complete documentation index at: https://kumo.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Regression

> Suggest Edits

* [Table of Contents](#)
* * * [Mean Absolute Error (MAE)](#mean-absolute-error-mae)
    * [Mean Squared Error (MSE)](#mean-squared-error-mse)
    * [Root Mean Squared Error (RMSE)](#root-mean-squared-error-rmse)
    * [Mean Absolute Percentage Error (MAPE)](#mean-absolute-percentage-error-mape)
    * [Symmetric Mean Absolute Percentage Error (SMAPE)](#symmetric-mean-absolute-percentage-error-smape)
  * [Heatmap of Predicted vs. Actual Values](#heatmap-of-predicted-vs-actual-values)
  * [Distribution of Predictions Histogram](#distribution-of-predictions-histogram)

For numerical predictions and labels, Kumo provides metrics for measuring the numerical distance between the actual and predicted values.

### Mean Absolute Error (MAE)

**MAE** is calculated by:

<img src="https://mintcdn.com/kumoai/ZKZPoQzuJb9d_Mqc/images/Screenshot2025-06-27at10.44.04AM.png?fit=max&auto=format&n=ZKZPoQzuJb9d_Mqc&q=85&s=aba0daf2f024901e4f9c0feed31bfe62" alt="Screenshot2025 06 27at10 44 04AM Pn" title="Screenshot2025 06 27at10 44 04AM Pn" style={{ width:"45%" }} width="384" height="152" data-path="images/Screenshot2025-06-27at10.44.04AM.png" />

where **\_yi \_**is the **\_ith \_**label and ***ŷi*** is the **\_ith \_**predicted value.

### Mean Squared Error (MSE)

**MSE** is calculated by:

<img src="https://mintcdn.com/kumoai/ZKZPoQzuJb9d_Mqc/images/Screenshot2025-06-27at10.44.27AM.png?fit=max&auto=format&n=ZKZPoQzuJb9d_Mqc&q=85&s=6993a370be5a6653d89502555c6520cf" alt="Screenshot2025 06 27at10 44 27AM Pn" title="Screenshot2025 06 27at10 44 27AM Pn" style={{ width:"41%" }} width="402" height="118" data-path="images/Screenshot2025-06-27at10.44.27AM.png" />

MSE focuses more on "how wrong" the prediction is. A prediction that is very far from the label will contribute more to increasing the MSE than the MAE.

### Root Mean Squared Error (RMSE)

**RMSE** is calculated by:

<img src="https://mintcdn.com/kumoai/ZKZPoQzuJb9d_Mqc/images/Screenshot2025-06-27at10.44.48AM.png?fit=max&auto=format&n=ZKZPoQzuJb9d_Mqc&q=85&s=f29706d9094efef5a39f31bfdad82ae1" alt="Screenshot2025 06 27at10 44 48AM Pn" title="Screenshot2025 06 27at10 44 48AM Pn" style={{ width:"28%" }} width="350" height="174" data-path="images/Screenshot2025-06-27at10.44.48AM.png" />

This score is in the same scale as the target and can be used even if a label is `0` or near `0`.

### Mean Absolute Percentage Error (MAPE)

**MAPE** is calculated by:

<img src="https://mintcdn.com/kumoai/ZKZPoQzuJb9d_Mqc/images/Screenshot2025-06-27at10.45.23AM.png?fit=max&auto=format&n=ZKZPoQzuJb9d_Mqc&q=85&s=44fe559b1d80fa15fb5ff06e7bd4d86b" alt="Screenshot2025 06 27at10 45 23AM Pn" title="Screenshot2025 06 27at10 45 23AM Pn" style={{ width:"32%" }} width="370" height="160" data-path="images/Screenshot2025-06-27at10.45.23AM.png" />

where **M** is the mean absolute percentage error, **At** is the actual value, and **Ft** is the forecast value.

MAPE is a common metric for evaluating models in regression problems, providing an intuitive measure for measuring accuracy.

### Symmetric Mean Absolute Percentage Error (SMAPE)

**SMAPE** is calculated by:

<img src="https://mintcdn.com/kumoai/ZKZPoQzuJb9d_Mqc/images/Screenshot2025-06-27at10.45.45AM.png?fit=max&auto=format&n=ZKZPoQzuJb9d_Mqc&q=85&s=2f390fa3b53df0aee9a4dab820887dd5" alt="Screenshot2025 06 27at10 45 45AM Pn" title="Screenshot2025 06 27at10 45 45AM Pn" style={{ width:"39%" }} width="352" height="174" data-path="images/Screenshot2025-06-27at10.45.45AM.png" />

SMAPE normalizes for the scale of the labels and also for the scale of the predictions. Similar to RMSE, this is especially useful if a label is `0` or near `0`.

***

## Heatmap of Predicted vs. Actual Values

Kumo provides a heatmap of predicted values versus the actual target labels for all entities in the predictive query, in your training table's holdout and evaluation set. This can be used to spot-check the quality of your trained predictive query. The predictions are generated by applying the trained predictive query to every single row in the training table that was generated during predictive query training. The actuals are the target labels from the training table.

<img src="https://mintcdn.com/kumoai/ZKZPoQzuJb9d_Mqc/images/Screenshot2025-06-27at10.45.51AM.png?fit=max&auto=format&n=ZKZPoQzuJb9d_Mqc&q=85&s=d18bf673e9c3a987b2e525357b4392ad" alt="Screenshot2025 06 27at10 45 51AM Pn" width="1316" height="1154" data-path="images/Screenshot2025-06-27at10.45.51AM.png" />

## Distribution of Predictions Histogram

Kumo also provides a histogram of the predicted values alongside the actual target labels for all entities in the predictive query, in the holdout and evaluation set of the training table. This can be used to spot-check the quality of your trained predictive query. The predictions are generated by applying the trained predictive query to every single row in the training table that was generated during predictive query training. The actuals are the target labels from the training table.

<img src="https://mintcdn.com/kumoai/ZKZPoQzuJb9d_Mqc/images/Screenshot2025-06-27at10.45.57AM.png?fit=max&auto=format&n=ZKZPoQzuJb9d_Mqc&q=85&s=610fb23c0e09ec878da387a7509e10c1" alt="Screenshot2025 06 27at10 45 57AM Pn" width="1328" height="688" data-path="images/Screenshot2025-06-27at10.45.57AM.png" />

Ideally, the shape of the two distributions should match; however, some divergence should be expected in normal cases, even for well-written predictive queries.

***
