update_SigmaINV_xCC | R Documentation |
\Sigma^{-1}
for xCC models
Gibbs sampling for \Sigma^{-1}
for xCC models
update_SigmaINV_xCC(x_data, z, y, Lambda, mu, K, alpha_sigma, beta_sigma)
x_data |
|
z |
Allocation vector |
y |
|
Lambda |
|
mu |
|
K |
Number of components |
alpha_sigma |
Prior parameter |
beta_sigma |
Prior parameter |
p\times p
matrix with the common variance of errors per component \Sigma^{-1} = \sigma I_p
.
Panagiotis Papastamoulis
library('fabMix')
# simulate some data
n = 8 # sample size
p = 5 # number of variables
q = 2 # number of factors
K = 2 # true number of clusters
sINV_diag = 1/((1:p)) # diagonal of inverse variance of errors
set.seed(100)
syntheticDataset <- simData(sameLambda=TRUE,K.true = K, n = n, q = q, p = p,
sINV_values = sINV_diag)
# use the real values as input and update SigmaINV
update_SigmaINV_xCC(x_data = syntheticDataset$data,
z = syntheticDataset$class,
y = syntheticDataset$factors,
Lambda = syntheticDataset$factorLoadings,
mu = syntheticDataset$means,
K = K,
alpha_sigma = 0.5, beta_sigma = 0.5)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.