The SSM procedure is designed for comprehensive state space modeling. It permits the specification of very general state space models and can be used to analyze a wide variety of sequential data types including univariate and multivariate time series, panel data, and longitudinal data. You build a state space model in PROC SSM by specifying a variety of matrices such as the state transition matrix, and the covariance matrices of the state and observation disturbances.

PROC SSM facilitates model specification in two ways. Firstly, it provides a programming language for specifying the elements of the model matrices that is similar to a DATA step. The matrix elements can be user-defined functions of data variables and unknown parameters. Secondly, the SSM procedure's syntax enables you to build larger models by composing smaller sub-models. In particular, the syntax enables you to easily specify models that include a wide variety of univariate and multivariate trends, cycles, seasonal patterns, and regression effects.

PROC SSM estimates the state space model parameters by maximum likelihood. The procedure computes the series forecasts and full sample estimates of the latent model effects, such as trend and seasonal components, by using the Kalman filter and smoother. An option is provided that enables you to save the series and component forecasts to a SAS data set.

The SSM procedure complements the capabilities of the SAS/ETS software's STATESPACE procedure, another state space modeling procedure. The STATESPACE procedure fits a much smaller set of state space models and requires that the data be of the time series type. In particular, the STATESPACE procedure does not permit time-varying system matrices, models with regression effects, and longitudinal data type. It does not produce full sample estimates of latent model effects and the parameter estimation is quasi-maximum likelihood rather than exact maximum likelihood. On the other hand, the STATESPACE procedure has some features that are absent in the SSM procedure, for example, a canonical correlation based automatic model identification facility.

For further details, see the *SAS/ETS ^{®} User's Guide*

- Example 33.1: Bivariate Basic Structural Model
- Example 33.2: Panel Data: Random-Effects and Autoregressive Models
- Example 33.3: Backcasting, Forecasting, and Interpolation
- Example 33.4: Longitudinal Data: Smoothing of Repeated Measures
- Example 33.5: A User-Defined Trend Model
- Example 33.6: Model with Multiple ARIMA Components
- Example 33.7: A Dynamic Factor Model for the Yield Curve
- Example 33.8: Diagnostic Plots and Structural Break Analysis
- Example 33.9: Longitudinal Data: Variable Bandwidth Smoothing
- Example 33.10: A Transfer Function Model for the Gas Furnace Data
- Example 33.11: Panel Data: Dynamic Panel Model for the Cigar Data
- Example 33.12: Multivariate Modeling: Long-Term Temperature Trends
- Example 33.13: Bivariate Model: Sales of Mink and Muskrat Furs
- Example 33.14: Factor Model: Now-Casting the US Economy
- Example 33.15: Longitudinal Data: Lung Function Analysis
- Example 33.16: Temporal Distribution: Estimating Monthly GDP
- Example 33.17: Temporal Aggregation: Triannual Nile River Level
- Example 33.18: Invariance of the Marginal Likelihood under Linear Rescaling of the Diffuse Effects