This function computes the log-likelihood for a markov-switching vector autoregressive model and uses the Hamilton smoother to obtain smoothed probabilities of each state. This is also the expectation step in the Expectation Maximization algorithm for a Markov-switching autoregressive model.
ExpectationM_MSVARmdl(theta, mdl, k)
List which includes log-likelihood and smoothed probabilities of each regime.
Vector of model parameters.
List with model attributes.
Integer determining the number of regimes.