Calculates logs of multivariate Gaussian densities with varying mean and varying covariance matrix AND EXCLUDING the constant term of the density (the constant is calculated and added in R code). The varying conditional covariance matrix is calculated within the function from the regime covariance matrices and transition weights.
obs: a (T×d) matrix such that the ith row contains the vector yi=(y1i,...,ydi)(dx1). That is, the initial values are excluded but the last observations is included.
means: a (T×d) matrix such that the ith row contains the conditional mean of the process μy,i.
covmats: a (d×d×M) array such that the slice [, , m]
contains the conditional covariance matrix of regime m.
alpha_mt: a (T×M) matrix such that [t, m] contains the time t transition weights of the mth regime.
Returns
a numeric vector containing the multivariate Gaussian densities, excluding the constant term.