statsmodels.tsa.statespace.simulation_smoother.SimulationSmoother

class statsmodels.tsa.statespace.simulation_smoother.SimulationSmoother(k_endog, k_states, k_posdef=None, simulation_smooth_results_class=None, simulation_smoother_classes=None, **kwargs)[source]

State space representation of a time series process, with Kalman filter and smoother, and with simulation smoother.

Parameters:

k_endog : {array_like, int}

The observed time-series process \(y\) if array like or the number of variables in the process if an integer.

k_states : int

The dimension of the unobserved state process.

k_posdef : int, optional

The dimension of a guaranteed positive definite covariance matrix describing the shocks in the measurement equation. Must be less than or equal to k_states. Default is k_states.

simulation_smooth_results_class : class, optional

Default results class to use to save output of simulation smoothing. Default is SimulationSmoothResults. If specified, class must extend from SimulationSmoothResults.

simulation_smoother_classes : dict, optional

Dictionary with BLAS prefixes as keys and classes as values.

**kwargs

Keyword arguments may be used to provide default values for state space matrices, for Kalman filtering options, for Kalman smoothing options, or for Simulation smoothing options. See Representation, KalmanFilter, and KalmanSmoother for more details.

Attributes

dtype (dtype) Datatype of currently active representation matrices
memory_no_filtered (bool) Flag to prevent storing filtered state and covariance matrices.
memory_no_forecast (bool) Flag to prevent storing all forecast-related output.
memory_no_predicted (bool) Flag to prevent storing predicted state and covariance matrices.
obs (array) Observation vector: \(y~(k\_endog \times nobs)\)
prefix (str) BLAS prefix of currently active representation matrices
time_invariant (bool) Whether or not currently active representation matrices are time-invariant
design  
endog  
obs_cov  
obs_intercept  
selection  
state_cov  
state_intercept  
transition  

Methods

bind(endog) Bind data to the statespace representation
clone(endog, **kwargs) Clone a state space representation while overriding some elements
extend(endog[, start, end]) Extend the current state space model, or a specific (time) subset
filter([filter_method, inversion_method, …]) Apply the Kalman filter to the statespace model.
fixed_scale(scale) Context manager for fixing the scale when FILTER_CONCENTRATED is set
get_simulation_output([simulation_output, …]) Get simulation output bitmask
impulse_responses([steps, impulse, …]) Impulse response function
initialize(initialization[, …]) Create an Initialization object if necessary
initialize_approximate_diffuse([variance]) Initialize the statespace model with approximate diffuse values.
initialize_diffuse() Initialize the statespace model as stationary.
initialize_known(constant, stationary_cov) Initialize the statespace model with known distribution for initial state.
initialize_stationary() Initialize the statespace model as stationary.
loglike(**kwargs) Calculate the loglikelihood associated with the statespace model.
loglikeobs(**kwargs) Calculate the loglikelihood for each observation associated with the statespace model.
set_conserve_memory([conserve_memory]) Set the memory conservation method
set_filter_method([filter_method]) Set the filtering method
set_filter_timing([alternate_timing]) Set the filter timing convention
set_inversion_method([inversion_method]) Set the inversion method
set_smooth_method([smooth_method]) Set the smoothing method
set_smoother_output([smoother_output]) Set the smoother output
set_stability_method([stability_method]) Set the numerical stability method
simulate(nsimulations[, measurement_shocks, …]) Simulate a new time series following the state space model
simulation_smoother([simulation_output, …]) Retrieve a simulation smoother for the statespace model.
smooth([smoother_output, smooth_method, …]) Apply the Kalman smoother to the statespace model.

Methods

bind(endog) Bind data to the statespace representation
clone(endog, **kwargs) Clone a state space representation while overriding some elements
extend(endog[, start, end]) Extend the current state space model, or a specific (time) subset
filter([filter_method, inversion_method, …]) Apply the Kalman filter to the statespace model.
fixed_scale(scale) Context manager for fixing the scale when FILTER_CONCENTRATED is set
get_simulation_output([simulation_output, …]) Get simulation output bitmask
impulse_responses([steps, impulse, …]) Impulse response function
initialize(initialization[, …]) Create an Initialization object if necessary
initialize_approximate_diffuse([variance]) Initialize the statespace model with approximate diffuse values.
initialize_diffuse() Initialize the statespace model as stationary.
initialize_known(constant, stationary_cov) Initialize the statespace model with known distribution for initial state.
initialize_stationary() Initialize the statespace model as stationary.
loglike(**kwargs) Calculate the loglikelihood associated with the statespace model.
loglikeobs(**kwargs) Calculate the loglikelihood for each observation associated with the statespace model.
set_conserve_memory([conserve_memory]) Set the memory conservation method
set_filter_method([filter_method]) Set the filtering method
set_filter_timing([alternate_timing]) Set the filter timing convention
set_inversion_method([inversion_method]) Set the inversion method
set_smooth_method([smooth_method]) Set the smoothing method
set_smoother_output([smoother_output]) Set the smoother output
set_stability_method([stability_method]) Set the numerical stability method
simulate(nsimulations[, measurement_shocks, …]) Simulate a new time series following the state space model
simulation_smoother([simulation_output, …]) Retrieve a simulation smoother for the statespace model.
smooth([smoother_output, smooth_method, …]) Apply the Kalman smoother to the statespace model.

Properties

conserve_memory
design
dtype (dtype) Datatype of currently active representation matrices
endog
filter_augmented
filter_collapsed
filter_concentrated
filter_conventional
filter_exact_initial
filter_extended
filter_method
filter_methods
filter_square_root
filter_timing
filter_univariate
filter_unscented
inversion_method
inversion_methods
invert_cholesky
invert_lu
invert_univariate
memory_conserve
memory_no_filtered (bool) Flag to prevent storing filtered state and covariance matrices.
memory_no_filtered_cov
memory_no_filtered_mean
memory_no_forecast (bool) Flag to prevent storing all forecast-related output.
memory_no_forecast_cov
memory_no_forecast_mean
memory_no_gain
memory_no_likelihood
memory_no_predicted (bool) Flag to prevent storing predicted state and covariance matrices.
memory_no_predicted_cov
memory_no_predicted_mean
memory_no_smoothing
memory_no_std_forecast
memory_options
memory_store_all
obs (array) Observation vector: \(y~(k\_endog \times nobs)\)
obs_cov
obs_intercept
prefix (str) BLAS prefix of currently active representation matrices
selection
simulation_outputs
smooth_alternative
smooth_classical
smooth_conventional
smooth_method
smooth_methods
smooth_univariate
smoother_all
smoother_disturbance
smoother_disturbance_cov
smoother_output
smoother_outputs
smoother_state
smoother_state_autocov
smoother_state_cov
solve_cholesky
solve_lu
stability_force_symmetry
stability_method
stability_methods
state_cov
state_intercept
time_invariant (bool) Whether or not currently active representation matrices are time-invariant
timing_init_filtered
timing_init_predicted
timing_options
transition