Zurück zu den Modellen
Metric

MeanArctangentAbsolutePercentageError

Mean Arctangent Absolute Percentage Error (MAAPE).

MAAPE is a variation of the Mean Absolute Percentage Error (MAPE) that is robust to zero values in the ground truth series. While MAPE is undefined when y_true=0, MAAPE uses the arctangent function to bound the error.

The formula is defined as:

\[\text{MAAPE} = \frac{1}{n} \sum_{t=1}^{n} \arctan \left(\left| \frac{y_t - \hat{y}_t}{y_t} \right| \right)\]

where \(y_t\) is the actual value and \(\hat{y}_t\) is the forecast value.

The result is bounded between 0 and \(\pi/2\) (approx 1.57).

Schnellstart

python
from sktime.performance_metrics.forecasting import MeanArctangentAbsolutePercentageError

estimator = MeanArctangentAbsolutePercentageError(multioutput='uniform_average', multilevel='uniform_average', relative_to='y_true', eps=None, by_index=False)

Parameter(5)

multioutput{‘raw_values’, ‘uniform_average’}, default=’uniform_average’
Defines aggregating of multiple output values.
multilevel{‘raw_values’, ‘uniform_average’}, default=’uniform_average’
Defines aggregating of multiple hierarchical levels.
relative_to{“y_true”, “y_pred”}, default=”y_true”
Determines the denominator of the percentage error.
epsfloat, default=None
Numerical epsilon used in denominator to avoid division by zero.
by_indexbool, default=False
If True, return the metric value at each time point. If False, return the aggregate metric value.

Referenzen

  1. Kim, S., & Kim, H. (2016). “A new metric of absolute percentage error for intermittent demand forecasts”. International Journal of Systems Science.