Computer Programs and Data to Accompany
StateSpace Models with RegimeSwitching:
Classical and GibbsSampling Approaches with Applications
All programs are written and Copyright ©1998 by ChangJin
Kim.
Please refer to http://econ.korea.ac.kr/~cjkim/SSMARKOV.htm
for conditions of use.
If you have any questions, please email ChangJin Kim either at
cjkim@korea.ac.kr or changjin@u.washington.edu.
Chapter 3  StateSpace Models and
the Kalman Filter
Chapter 4  MarkovSwitching Models
Chapter 5  StateSpace Models with MarkovSwitching
Chapter 6  StateSpace Models with Heteroskedastic
Disturbances
Chapter 7  An Introduction to Bayesian Inference
and Gibbs Sampling
Chapter 8  StateSpace Models and Gibbs Sampling
Chapter 9  MarkovSwitching Models and Gibbs
Sampling
Chapter 10  StateSpace Models with MarkovSwitching
and Gibbs Sampling
Chapter 11  Gibbs Sampling and Parameter
Uncertainty: Testing for Mean Reversion in Heteroskedastic Data
Return to the top
Chapter 3  StateSpace Models and the
Kalman Filter
Application #1: A Decomposition of Real GDP and the Unemployment
Rate into Stochastic Trend and Transitory Components
Application #2: An Application of the TimeVarying Parameter Model
to Modeling Changing Conditional Variance
Application #3: Stock & Watson's (1991) Dynamic Factor Model
of the Coincident Economic Indicators
Programs:
TVP.OPT  A TimeVarying
Parameter Model of U.S. Monetary Growth Function: Based on Kim and
Nelson (1989)
UC_UNI.OPT  A Univariate
Unobserved Components Model of U.S. Real GDP: Based on Clark (1987)
UC_BI.OPT  A Bivariate
Unobserved Components Model of U.S. Real GDP and the Unemployment
Rate: Based on Clark (1989)
S&W.OPT  A
Dynamic Factor Model of Four Coincident Economic Indicators: An
Experimental Coincident Index: Based on Stock and Watson (1991)
Data:
TVP.PRN  see program for
details
GDP4795.PRN  Real
GDP
LHUR.PRN  Unemployment
Rate
S&W.PRN  see program
for details
Return to chapter list
Chapter 4  MarkovSwitching Models
Application #1: Hamilton's (1989) MarkovSwitching Model of Business
Fluctuations
Application #2: A Unit Root in a ThreeState MarkovSwitching Model
of the Real Interest Rate
Application #3: A ThreeState MarkovSwitching Model of Stock Returns
Programs:
HMT4_KIM.OPT 
An AR(4) Model with a MarkovSwitching Mean (2state): Based on
Hamilton's (1989) Filter and Kim's (1994) Smoothing
HMT4_DMY.OPT 
An AR(4) Model with a MarkovSwitching Mean (2state): Based on
Hamilton's (1989) Filter and Kim's (1994) Smoothing (Dummy variables
are incorporated for the mean growth rates)
INTR_S3.OPT  A
ThreeState MarkovSwitching MeanVariance Model of the Real Interst
Rate: Based on Garcia and Perron (1996)
STCK_V3.OPT  A
ThreeState MarkovSwitching Variance Model of Stock Returns: Based
on Kim, Nelson, and Startz (1997)
HMT_TVP.OPT  An
AR(4) Model with a MarkovSwitching Mean (2state) and TimeVarying
Transition Probabilities: Based on Filardo (1994)
Data:
GDP4795.PRN  Real
GDP
INT_CPUQ.PRN  see
program for details
EW_EXCS.PRN  EqualWeighted
Excess Returns
FILARDO.PRN see program
for details
Return to chapter list
Chapter 5  StateSpace Models with MarkovSwitching
Application #1: Sources of Monetary Growth Uncertainty and Economic
Activity
Application #2: Friedman's Plucking Model of Business Fluctuations
and Implied Business Cycle Asymmetry
Application #3: A Dynamic Factor Model with MarkovSwitching: Business
Cycle Turning Points and a New Coincident Index
Programs:
KIM_JE0.OPT  not
available at this time
KIM_JE1.OPT  A
StateSpace Representation of Lam's (1990) Gerneralized Hamilton
Model and Kim's (1994) Filter(easier version)
TVPMRKF.OPT  TimeVaryingParameter
Model with MarkovSwitching Heteroskedasticity: Based on Kim (1993)
TVPM_JNT.OPT 
TimeVaryingParameter Model with MarkovSwitching Heteroskedasticity:
Based on Kim (1993); A Joint Estimation of the Output Equation and
the Monetary Growth Equation
SW_MS.OPT  Dynamic
Factor Model with MarkovSwitching (A New Coicident Index): An Application
of Kim's (1994) Algorithm by Kim and Yoo (1995)
Data:
KIM_JE.PRN  see program
for details
TVPMRKF.PRN  see program
for details
SW_MS.PRN  see program
for details
Return to chapter list
Chapter 6  StateSpace Models with Heteroskedastic
Disturbances
Application #1: The Link Between the Inflation Rate and Inflation
Uncertainty
Application #2: Transient Fads and the Crash of '87 in the U.S.
Stock Market
Programs:
TVPGRCH.OPT  A
TimeVaryingParameter Model with GARCH(1,1) Disturbances: Based
on Harvey et. al. (1992)
INF_FNL.OPT  A
StateSpace Model with MarkovSwitching Heteroskedasticity: A Model
of the Inflation Rate (Large and Infrequent Permanent Shocks to
Inflation): Based on Kim (1993)
STCK.OPT  A Fad Model
of Stock Returns(Transient Fads): based on Kim and M. Kim (1996)
GARCH.OPT  GARCH(1,1)
Model of Stock Returns
STCK_V2.OPT  A
TwoState MarkovSwitching Model of Stock Returns
Data:
TVPGRCH.PRN  see program
for details
GD4795.PRN  GDP Deflator
RSP2692.PRN  see
program for details
TURNER3.PRN  see
program for details
<Return to chapter list
Chapter 7  An Introduction to Bayesian Inference
and Gibbs Sampling
Programs:
GBS_AR4.PRG  A
GibbsSampling Approach to a Linear AR(4) Model
MLE_AR4.PRG  A
Maximum Likelihood Estiamtion of a Linear AR(4) Model
GBS_ATO.PRG  A
GibbsSampling Approach to a Regression Model with AR(1) Disturbances
MLE_ATO.PRG  A
Maximum Likelihood Estiamtion of a Regression Model with AR(1) Disturbances
Data:
GDP4795.PRN  Real
GDP
Return to chapter list
Chapter 8  StateSpace Models and Gibbs
Sampling
Application #1: A GibbsSampling Approach to a Linear Dynamic Factor
Model and a New Coincident Index
Program:
SW_GIBS.PRG  A
GibbsSampling Approach to Stock and Watson's Dynamic Factor Model
of 4 Coincident Economic Indicators: A New Experimental Coincident
Index
Data:
FULLDTA.PRN  see program
for details
Return to chapter list
Chapter 9  MarkovSwitching Models and Gibbs
Sampling
Application #1: A ThreeState MarkovSwitching Variance Model of
Stock Returns
Application #2: A ThreeState MarkovSwitching MeanVariance Model
of the Real Interest Rate
Program:
GIBS_MS0.PRG 
A GibbsSampling Approach to an AR(0) Model with a TwoState MarkovSwitching
Mean, Homoskedastic Disturbances: MultiMove Gibbs Sampling [For
Real GDP Data]
GIBS_S3.PRG  A
GibbsSampling Approach to a ThreeState MarkovSwitching Variance
Model of Stock Returns: Multimove GibbsSampling
G_INT_S3.PRG 
A GibbsSampling Approach to a ThreeState MarkovSwitching MeanVariance
AR(2) Model of the Real Interest Rate: Multimove GibbsSampling
Data:
GDP4795.PRN  Real
GDP
CRSPD.PRN  see program
for details
INT_CPUQ.PRN  see
program for details
Return to chapter list
Chapter 10  StateSpace Models with MarkovSwitching
and Gibbs Sampling
Application #1: Business Cycle Turning Points and a New Coincident
Index
Application #2: Business Cycle Duration Dependence within a Dynamic
Factor Model
Application #3: An Unobserved Component Model of the LongRun U.S./U.K.
Real Exchange Rate with Heteroskedasticity
Programs:
SWMSGIBS.PRG 
A GibbsSampling Approach to a Dynamic Factor Model with MarkovSwitching:
Based on Kim and Nelson (1998)
Data:
FULLDTA.PRN  see program
for details
Return to chapter list
Chapter 11 Gibbs Sampling and Parameter
Uncertainty: Testing for Mean Reversion in Heteroskedastic Data
VR_HT_OR.PRG 
VR Test Based on GibbsSamplingAugmented Randomization, original
returns: Based on Kim, Nelson, and Startz (1998)
VR_HT_ST.PRG 
VR Test Based on GibbsSamplingAugmented Randomization, standardized
returns: Based on Kim, Nelson, and Startz (1998)
Data:
CRSPD.PRN  see program
for details
Return to chapter list
