sampleSemisupervisedMVN {batchmix}R Documentation

Sample semi-supervised MVN Mixture model

Description

Performs MCMC sampling for a mixture model.

Usage

sampleSemisupervisedMVN(
  X,
  K,
  B,
  labels,
  batch_vec,
  fixed,
  mu_proposal_window,
  cov_proposal_window,
  m_proposal_window,
  S_proposal_window,
  R,
  thin,
  concentration,
  m_scale,
  rho,
  theta,
  initial_mu,
  initial_cov,
  initial_m,
  initial_S,
  mu_initialised,
  cov_initialised,
  m_initialised,
  S_initialised,
  sample_m_scale
)

Arguments

X

The data matrix to perform clustering upon (items to cluster in rows).

K

The number of components to model (upper limit on the number of clusters found).

B

The number of batches to model.

labels

Vector item labels to initialise from.

batch_vec

Observed batch labels.

fixed

Binary vector of the items that are fixed in their initial label.

mu_proposal_window

The standard deviation for the Gaussian proposal density of the cluster means.

cov_proposal_window

The degrees of freedom for the Wishart proposal density of the cluster covariances.

m_proposal_window

The standard deviation for the Gaussian proposal density of the batch mean effects.

S_proposal_window

The rate for the Gamma proposal density of the batch scale.

R

The number of iterations to run for.

thin

thinning factor for samples recorded.

concentration

Vector of concentrations for mixture weights (recommended to be symmetric).

m_scale

The scale hyperparameter for the batch shift prior distribution.

rho

The shape of the prior distribution for the batch scale.

theta

The scale of the prior distribution for the batch scale.

initial_mu

A P x K matrix of initial values for the class means.

initial_cov

A P x P x K cube of initial values for the class covariance matrices.

initial_m

A P x B matrix of initial values for the batch shift effects.

initial_S

A P x B matrix of initial values for the batch scales.

mu_initialised

Bool indicating if the class means are initialised by the user. If “false“ then initial values are drawn from the prior distribution.

cov_initialised

Bool indicating if the class covariance matrices are initialised by the user. If “false“ then initial values are drawn from the prior distribution.

m_initialised

Bool indicating if the batch shift effects are initialised by the user. If “false“ then initial values are drawn from the prior distribution.

S_initialised

Bool indicating if the batch scales are initialised by the user. If “false“ then initial values are drawn from the prior distribution.

sample_m_scale

Bool indicating if the hyperparameter on the batch shift effect is sampled or given as fixed.

Value

Named list of the different quantities drawn by the sampler.


[Package batchmix version 2.2.1 Index]