Thanks...This is exactly as I thought...The problem is that there are no non-switching independent parameters in this case. Setting nS_param to the null vector produces an error
Awesome code. I am really trying to do something absurdly simple here, which might be the problem. I want to generate a univariate two-state Markov regime switching process, where the series is only related to a regime-dependent mean (e.g. the only independent variable is a column of ones). Can MS_Regress_Sim.m be used for this purpose>