ARIMA
arima.ARIMA · inherits BaseForecaster
Represents a fixed-order ARIMA forecaster that standardizes training data for optimization stability and returns forecasts in the original value scale.
Attributes:
* uses_exog: True
* alias: Display name for external reporting.
* model_: dict[str, Any] | None. Fitted model payload after fit.
__init__(self, order=(0, 0, 0), seasonal_order=(0, 0, 0), period=1, include_mean=True, method='CSS', alias='ARIMA', standardize=True)
Initialize a fixed-order ARIMA estimator.
| Parameter | Type | Default | Description |
|---|---|---|---|
order |
tuple[int, int, int] |
(0, 0, 0) |
Non-seasonal order (p, d, q). |
seasonal_order |
tuple[int, int, int] |
(0, 0, 0) |
Seasonal order (P, D, Q). |
period |
int |
1 |
Seasonal cycle length. |
include_mean |
bool |
True |
Whether to include deterministic mean/drift. |
method |
str |
"CSS" |
Objective method strategy. |
alias |
str |
"ARIMA" |
User-facing model name. |
standardize |
bool |
True |
Enables series standardization. |
fit(self, y, X=None) -> Self
Fit ARIMA parameters on a training series.
Parameters:
| Parameter | Type | Default | Description |
|---|---|---|---|
y |
jnp.ndarray |
- | Training target series. |
X |
Optional[jnp.ndarray] |
None |
Optional exogenous matrix aligned with y. |
Returns: Self (The fitted estimator instance; sets self.model_).
Raises: RuntimeError (Propagated from fitting internals if optimization fails irrecoverably.)
forecast(self, h, y, X=None, X_future=None, level=None, fitted=False) -> dict[str, jnp.ndarray]
Fit and forecast in one call.
Parameters:
| Parameter | Type | Default | Description |
|---|---|---|---|
h |
int |
- | Forecast horizon. |
y |
jnp.ndarray |
- | Source training series. |
X |
Optional[jnp.ndarray] |
None |
Exogenous regressors. The fast path currently does not use exogenous variables. |
X_future |
Optional[jnp.ndarray] |
None |
Future exogenous regressors (unused; included for BaseForecaster compliance). |
level |
Optional[list] |
None |
Confidence levels (unused; included for BaseForecaster compliance). |
fitted |
bool |
False |
Whether to return fitted values (unused; included for BaseForecaster compliance). |
Returns: dict[str, jnp.ndarray] (Forecast dictionary containing mean).
Raises: RuntimeError (Propagated if optimizer objective diverges.)
predict(self, h, X=None, level=None) -> dict[str, jnp.ndarray]
Generate forecasts from a fitted ARIMA model.
Parameters:
| Parameter | Type | Default | Description |
|---|---|---|---|
h |
int |
- | Number of future steps to predict. |
X |
Optional[jnp.ndarray] |
None |
Optional exogenous future matrix. |
level |
int \| tuple[int, ...] \| None |
None |
Confidence levels for interval generation. |
Returns: dict[str, jnp.ndarray] (Dictionary containing mean and optional lower/upper interval keys (e.g., lo-95, hi-95).)
Raises: RuntimeError (If called before fit.)