get_alpha_mt
computes the mixing weights based on
the logarithm of the multivariate normal densities in the definition of
the mixing weights.
get_alpha_mt(M, log_mvnvalues, alphas, epsilon, conditional, also_l_0 = FALSE)
a positive integer specifying the number of mixture components.
\(T x M\) matrix containing the log multivariate normal densities.
\(M x 1\) vector containing the mixing weight pa
the smallest number such that its exponent is wont classified as numerically zero
(around -698
is used).
a logical argument specifying whether the conditional or exact log-likelihood function should be used.
return also l_0 (the first term in the exact log-likelihood function)?
Returns the mixing weights a matrix of the same dimension as log_mvnvalues
so
that the t:th row is for the time point t and m:th column is for the regime m.
Note that we index the time series as \(-p+1,...,0,1,...,T\) as in Kalliovirta et al. (2016).
Kalliovirta L., Meitz M. and Saikkonen P. 2016. Gaussian mixture vector autoregression. Journal of Econometrics, 192, 485-498.
Virolainen S. 2020. Structural Gaussian mixture vector autoregressive model. Unpublished working paper, available as arXiv:2007.04713.