lmn_post | R Documentation |
Calculates the parameters of the LMN model's Matrix-Normal Inverse-Wishart (MNIW) conjugate posterior distribution (see Details).
lmn_post(suff, prior)
suff |
An object of class |
prior |
A list with elements |
The Matrix-Normal Inverse-Wishart (MNIW) distribution (B, Σ) ~ MNIW(Λ, Ω, Ψ, ν) on random matrices X_(p x q) and symmetric positive-definite Σ_(q x q) is defined as
Σ ~ Inverse-Wishart(Ψ, ν)
B | Σ ~ Matrix-Normal(Λ, Ω^{-1}, Σ),
where the Matrix-Normal distribution is defined in lmn_suff()
.
The posterior MNIW distribution is required to be a proper distribution, but the prior is not. For example, prior = NULL
corresponds to the noninformative prior
π(B, Σ) ~ |Σ|^{-(q+1)/2}.
A list with elements named as in prior
specifying the parameters of the posterior MNIW distribution. Elements Omega = NA
and nu = NA
specify that parameters Beta = 0
and Sigma = diag(q)
, respectively, are known and not to be estimated.
# generate data n <- 50 q <- 2 p <- 3 Y <- matrix(rnorm(n*q),n,q) # response matrix X <- matrix(rnorm(n*p),n,p) # covariate matrix V <- .5 * exp(-(1:n)/n) # Toeplitz variance specification suff <- lmn_suff(Y = Y, X = X, V = V, Vtype = "acf") # sufficient statistics
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.