Draw from finite or infinite (Dirichlet process) multivariate normal mixture model. Note that although correlations are allowed for each mixture component, the locations of components are drawn from a multivariate normal distribution with standard deviation tau in all directions (i.e. no correlation). Allows for generation of missing data by randomly eliminating a proportion of results.
1 | rMultiMix(n, K, psi, nu, alpha, tau, pMissing = 0)
|
n |
number of draws. |
K |
number of mixture components. Set K=Inf to use infinite mixture model. |
psi |
prior matrix for inverse Wishart prior on covariance. When psi is a scalar value the model is one-dimensional, and variances are effectively drawn from an inverse-gamma distribution with shape alpha=nu/2 and rate beta=psi/2. |
nu |
degrees of freedom for inverse Wishart prior on covariance. |
alpha |
Dirichlet prior parameter for mixture weights. Set alpha=Inf to use model of equal weights. |
tau |
standard deviation of prior on individual components means (this prior is centred at 0). |
pMissing |
proportion of data that is missing. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.