'Apply the Kalman smoother to the statespace model.
Parameters
smoother_output : int, optional
Determines which Kalman smoother output calculate. Default is all
(including state, disturbances, and all covariances).
results : class or object, optional
If a class, then that class is instantiated and returned with the
result of both filtering and smoothing.
If an object, then that object is updated with the smoothing data.
If None, then a SmootherResults object is returned with both
filtering and smoothing results.
run_filter : bool, optional
Whether or not to run the Kalman filter prior to smoothing. Default
is True.
prefix : string
The prefix of the datatype. Usually only used internally.
Returns
SmootherResults object'

def smooth(self, smoother_output=None, smooth_method=None, results=None, run_filter=True, prefix=None, complex_step=False, **kwargs):

    kfilter = self._filter(**kwargs)
    results = self.results_class(self)
    results.update_representation(self)
    results.update_filter(kfilter)
    if (smoother_output is None):
        smoother_output = self.smoother_output
    smoother = self._smooth(smoother_output, results=results, **kwargs)
    results.update_smoother(smoother)
    return results
