Transformer
NonNegativeOptimalReconciler
Inverse TransformationReihen ungleicher Länge
Apply non-negative reconciliation to hierarchical time series.
Uses all the forecasts to obtain a reconciled forecast, avoiding negative values.
The optimization problem tries to find the bottom forecasts $b$ which are non-negative and minimize the distance between the base forecasts and the reconciled forecasts, given the invertion of error covariance matrix $E$ as a weighting matrix.
Schnellstart
python
from sktime.transformations.hierarchical.reconcile import NonNegativeOptimalReconciler
estimator = NonNegativeOptimalReconciler(error_covariance_matrix: DataFrame=None, alpha=0)Tags
Fähigkeiten
- Inverse Transformation: Unterstützt
- Reihen ungleicher Länge
- Multivariat: Nicht unterstützt
- Fehlende Werte: Nicht unterstützt
- Entfernt fehlende Werte: Nicht unterstützt
- Gleicht Reihenlängen an: Nicht unterstützt
Eigenschaften
- Eingabetypscitype:transform-input
- Series
- Ausgabetypscitype:transform-output
- Series
- Label-Typscitype:transform-labels
- None
- Fit ist leerfit_is_empty
- Nein
- Behält den Zeitindextransform-returns-same-time-index
- Nein
- Benötigt Xrequires_X
- Ja
- Benötigt yrequires_y
- Nein
- X und y brauchen denselben IndexX-y-must-have-same-index
- Nein
Parameter(2)
- error_covariance_matrixpd.DataFrame, default=None
- Error covariance matrix. If None, it is assumed to be the identity matrix
- alphafloat, default=0
- Constant added to the diagonal of the inverted matrix.
Beispiele
>>> from sktime.transformations.hierarchical.reconcile import (
... NonNegativeOptimalReconciler)
>>> from sktime.utils._testing.hierarchical import _make_hierarchical
>>> from sktime.forecasting.exp_smoothing import ExponentialSmoothing
>>> y = _make_hierarchical ()
>>> pipe = NonNegativeOptimalReconciler () * ExponentialSmoothing ()
>>> pipe = pipe. fit (y)
>>> y_pred = pipe. predict (fh = [1, 2, 3 ])