class_docstr: State space representation of a time series process, with Kalman filter
  and smoother.
  
  Parameters
  ----------
  k_endog : {array_like, int}
      The observed time-series process :math:`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`.
  results_class : class, optional
      Default results class to use to save filtering output. Default is
      `SmootherResults`. If specified, class must extend from
      `SmootherResults`.
  **kwargs
      Keyword arguments may be used to provide default values for state space
      matrices, for Kalman filtering options, or for Kalman smoothing
      options. See `Representation` for more details.
code: def __init__(
      self,
      k_endog,
      k_states,
      k_posdef=None,
      results_class=None,
      kalman_smoother_classes=None,
      **kwargs,
  ):
      # Set the default results class
      if results_class is None:
          results_class = SmootherResults
  
      # Extract keyword arguments to-be-used later
      keys = ["smoother_output"] + KalmanSmoother.smoother_outputs
      smoother_output_kwargs = {
          key: kwargs.pop(key) for key in keys if key in kwargs
      }
      keys = ["smooth_method"] + KalmanSmoother.smooth_methods
      smooth_method_kwargs = {
          key: kwargs.pop(key) for key in keys if key in kwargs
      }
  
      # Initialize the base class
      super().__init__(
          k_endog,
          k_states,
          k_posdef,
          results_class=results_class,
          **kwargs,
      )
  
      # Options
      self.prefix_kalman_smoother_map = (
          kalman_smoother_classes
          if kalman_smoother_classes is not None
          else tools.prefix_kalman_smoother_map.copy()
      )
  
      # Setup the underlying Kalman smoother storage
      self._kalman_smoothers = {}
  
      # Set the smoother options
      self.set_smoother_output(**smoother_output_kwargs)
      self.set_smooth_method(**smooth_method_kwargs)
  
imports: import numpy
  from types import SimpleNamespace
  from statsmodels.tsa.statespace.representation import OptionWrapper
  from statsmodels.tsa.statespace.kalman_filter import KalmanFilter, FilterResults
  from statsmodels.tsa.statespace.tools import reorder_missing_matrix, reorder_missing_vector, copy_index_matrix
  from statsmodels.tsa.statespace import tools, initialization
label_desc: Use image node_id 1 to create a new KalmanSmoother object from inherited base classes: KalmanFilter with example: obj = KalmanSmoother(k_endog, k_states, k_posdef, results_class, kalman_smoother_classes)