statsmodels.tsa.statespace.kalman_smoother.SmootherResults

class statsmodels.tsa.statespace.kalman_smoother.SmootherResults(model)[source]

Results from applying the Kalman smoother and/or filter to a state space model.

Parameters:
model : Representation

A Statespace representation

nobs

Number of observations.

Type:

int

k_endog

The dimension of the observation series.

Type:

int

k_states

The dimension of the unobserved state process.

Type:

int

k_posdef

The dimension of a guaranteed positive definite covariance matrix describing the shocks in the measurement equation.

Type:

int

dtype

Datatype of representation matrices

Type:

dtype

prefix

BLAS prefix of representation matrices

Type:

str

shapes

A dictionary recording the shapes of each of the representation matrices as tuples.

Type:

dictionary of name:tuple

endog

The observation vector.

Type:

ndarray

design

The design matrix, \(Z\).

Type:

ndarray

obs_intercept

The intercept for the observation equation, \(d\).

Type:

ndarray

obs_cov

The covariance matrix for the observation equation \(H\).

Type:

ndarray

transition

The transition matrix, \(T\).

Type:

ndarray

state_intercept

The intercept for the transition equation, \(c\).

Type:

ndarray

selection

The selection matrix, \(R\).

Type:

ndarray

state_cov

The covariance matrix for the state equation \(Q\).

Type:

ndarray

missing

An array of the same size as endog, filled with boolean values that are True if the corresponding entry in endog is NaN and False otherwise.

Type:

array of bool

nmissing

An array of size nobs, where the ith entry is the number (between 0 and k_endog) of NaNs in the ith row of the endog array.

Type:

array of int

time_invariant

Whether or not the representation matrices are time-invariant

Type:

bool

initialization

Kalman filter initialization method.

Type:

str

initial_state

The state vector used to initialize the Kalamn filter.

Type:

array_like

initial_state_cov

The state covariance matrix used to initialize the Kalamn filter.

Type:

array_like

filter_method

Bitmask representing the Kalman filtering method

Type:

int

inversion_method

Bitmask representing the method used to invert the forecast error covariance matrix.

Type:

int

stability_method

Bitmask representing the methods used to promote numerical stability in the Kalman filter recursions.

Type:

int

conserve_memory

Bitmask representing the selected memory conservation method.

Type:

int

tolerance

The tolerance at which the Kalman filter determines convergence to steady-state.

Type:

float

loglikelihood_burn

The number of initial periods during which the loglikelihood is not recorded.

Type:

int

converged

Whether or not the Kalman filter converged.

Type:

bool

period_converged

The time period in which the Kalman filter converged.

Type:

int

filtered_state

The filtered state vector at each time period.

Type:

ndarray

filtered_state_cov

The filtered state covariance matrix at each time period.

Type:

ndarray

predicted_state

The predicted state vector at each time period.

Type:

ndarray

predicted_state_cov

The predicted state covariance matrix at each time period.

Type:

ndarray

kalman_gain

The Kalman gain at each time period.

Type:

ndarray

forecasts

The one-step-ahead forecasts of observations at each time period.

Type:

ndarray

forecasts_error

The forecast errors at each time period.

Type:

ndarray

forecasts_error_cov

The forecast error covariance matrices at each time period.

Type:

ndarray

loglikelihood

The loglikelihood values at each time period.

Type:

ndarray

collapsed_forecasts

If filtering using collapsed observations, stores the one-step-ahead forecasts of collapsed observations at each time period.

Type:

ndarray

collapsed_forecasts_error

If filtering using collapsed observations, stores the one-step-ahead forecast errors of collapsed observations at each time period.

Type:

ndarray

collapsed_forecasts_error_cov

If filtering using collapsed observations, stores the one-step-ahead forecast error covariance matrices of collapsed observations at each time period.

Type:

ndarray

standardized_forecast_error

The standardized forecast errors

Type:

ndarray

smoother_output

Bitmask representing the generated Kalman smoothing output

Type:

int

scaled_smoothed_estimator

The scaled smoothed estimator at each time period.

Type:

ndarray

scaled_smoothed_estimator_cov

The scaled smoothed estimator covariance matrices at each time period.

Type:

ndarray

smoothing_error

The smoothing error covariance matrices at each time period.

Type:

ndarray

smoothed_state

The smoothed state at each time period.

Type:

ndarray

smoothed_state_cov

The smoothed state covariance matrices at each time period.

Type:

ndarray

smoothed_state_autocov

The smoothed state lago-one autocovariance matrices at each time period: \(Cov(\alpha_{t+1}, \alpha_t)\).

Type:

ndarray

smoothed_measurement_disturbance

The smoothed measurement at each time period.

Type:

ndarray

smoothed_state_disturbance

The smoothed state at each time period.

Type:

ndarray

smoothed_measurement_disturbance_cov

The smoothed measurement disturbance covariance matrices at each time period.

Type:

ndarray

smoothed_state_disturbance_cov

The smoothed state disturbance covariance matrices at each time period.

Type:

ndarray

Methods

get_smoothed_decomposition([...])

Decompose smoothed output into contributions from observations

news(previous[, t, start, end, ...])

Compute the news and impacts associated with a data release

predict([start, end, dynamic])

In-sample and out-of-sample prediction for state space models generally

smoothed_state_autocovariance([lag, t, ...])

Compute state vector autocovariances, conditional on the full dataset

smoothed_state_gain(updates_ix[, t, start, ...])

Cov(tilde alpha_{t}, I) Var(I, I)^{-1}

update_filter(kalman_filter)

Update the filter results

update_representation(model[, only_options])

Update the results to match a given model

update_smoother(smoother)

Update the smoother results

Properties

kalman_gain

Kalman gain matrices

smoothed_forecasts

smoothed_forecasts_error

smoothed_forecasts_error_cov

standardized_forecasts_error

Standardized forecast errors