Publisher review:Estimation of a Markov Switching Regression Model - Function to estimate a MS regression in matlab This submission provides a function for estimation of a general Markov Switching Regression with k states and any number of regressors. The model also switches in the standard deviationThe main advantage in this function is that you can select which variables will have MS effect and which won't with the use of input argument S. As example, suppose you have a indep matrix with 3 columns (3 explanatory variables). You don't want to have Markov Switching effect in all parameters, but just in variables 1 and 3 (collums 1 and 3 at indep). For that you just set S=[1 0 1] and the function will estimate the model according to your MS choice (value 1 for MS effect, value 0 for no MS effect). Easy isn't it.With a few matrix manipulations (eg. ones()) you can include constants, autoregressive parameters and any other non latent type of explanatory variable which characterizes your econometric model.
Input:dep - Dependent Variable (vector)indep - Independent variables (a.k.a explanatory variables), can be a vector (one variable) or a matrixk - Number of States S - This variable controls for where to include a Markov Switching effect. Output:Spec_Output - A structure with following fields:LL - Log likelihood of fitted modelProbs - States probabilities over time (each column represents each state, ascending order).Coeff - All estimated coefficients for each state (regression parameters, standard deviation, transition matrix, etc..) Each column represents each state, ascending order). Requirements: · MATLAB Release: R2006a · Optimization Toolbox · Statistics Toolbox
Estimation of a Markov Switching Regression Model is a Matlab script for Earth Sciences scripts design by Marcelo Scherer Perlin.
It runs on following operating system: Windows / Linux / Mac OS / BSD / Solaris.
Estimation of a Markov Switching Regression Model - Function to estimate a MS regression in matlab
Operating system:Windows / Linux / Mac OS / BSD / Solaris