Dynamic-factor models were introduced in Stata 11.
|
Order |
Stata’s new dfactor command estimates the parameters of dynamic-factor models by maximum likelihood. Dynamic-factor models are flexible models for multivariate time series in which the observed endogenous variables are linear functions of exogenous covariates and unobserved factors, which have a vector autoregressive structure. The unobserved factors may also be a function of exogenous covariates. The disturbances in the equations for the dependent variables may be autocorrelated.
We have data on industrial production (ipman), real disposable income (dsp), weekly hours worked (awhi), and the unemployment rate (unrate). We suspect there exists a latent factor that can explain all four of these series, and we conjecture that latent factor follows an AR(2) process.
The first step is to fit our model:
With our model fit, let’s obtain dynamic forecasts for disposable income beginning in December 2008:
. tsappend, add(3) . predict dsp_f, dynamic(tm(2008m12)) . tsline dsp dsp_f if month >= tm(2005m1)
Even more interesting is the path of our unobserved factor. We have hypothesized that all our observed variables follow the unobserved latent factor. We can obtain the one-step predictions of the factor by typing
. predict factor, factor
We can then trace the path of the factor by graphing the result:
. tsline factor
Extracting the latent factor in this manner is sometimes referred to as extracting or estimating an indicator.
dfactor also estimates the parameters of static-factor models, seemingly unrelated regression (SUR) models, and vector autoregressive (VAR) models by maximum likelihood. dfactor allows for constraints on the covariance matrix of the errors in an SUR model and a VAR model.
After estimation, you can predict both the endogenous variables and the unobserved factors. In addition to one-step predictions, dfactor can produce dynamic multistep predictions.
For a complete list of what’s new in time-series analysis, click here.
Learn
Free webinars
NetCourses
Classroom and web training
Organizational training
Video tutorials
Third-party courses
Web resources
Teaching with Stata
© Copyright 1996–2024 StataCorp LLC. All rights reserved.
×
We use cookies to ensure that we give you the best experience on our website—to enhance site navigation, to analyze usage, and to assist in our marketing efforts. By continuing to use our site, you consent to the storing of cookies on your device and agree to delivery of content, including web fonts and JavaScript, from third party web services.
Cookie Settings
Last updated: 16 November 2022
StataCorp LLC (StataCorp) strives to provide our users with exceptional products and services. To do so, we must collect personal information from you. This information is necessary to conduct business with our existing and potential customers. We collect and use this information only where we may legally do so. This policy explains what personal information we collect, how we use it, and what rights you have to that information.
These cookies are essential for our website to function and do not store any personally identifiable information. These cookies cannot be disabled.
This website uses cookies to provide you with a better user experience. A cookie is a small piece of data our website stores on a site visitor's hard drive and accesses each time you visit so we can improve your access to our site, better understand how you use our site, and serve you content that may be of interest to you. For instance, we store a cookie when you log in to our shopping cart so that we can maintain your shopping cart should you not complete checkout. These cookies do not directly store your personal information, but they do support the ability to uniquely identify your internet browser and device.
Please note: Clearing your browser cookies at any time will undo preferences saved here. The option selected here will apply only to the device you are currently using.