Learn R Programming

BayesBinMix (version 1.4.1)

gibbsBinMix: Standard Gibbs sampler

Description

This function implements full Gibbs sampling to simulate an MCMC sample from the posterior distribution assuming known number of mixture components.

Usage

gibbsBinMix(alpha, beta, gamma, K, m, burn, data, 
	thinning, z.true, outputDir)

Arguments

alpha

First shape parameter of the Beta prior distribution (strictly positive). Defaults to 1.

beta

Second shape parameter of the Beta prior distribution (strictly positive). Defaults to 1.

gamma

Kmax-dimensional vector (positive) corresponding to the parameters of the Dirichlet prior of the mixture weights. Default value: rep(1,Kmax).

K

Number of clusters.

m

Number of MCMC iterations.

burn

Burn-in period.

data

Binary data.

thinning

Thinning of the simulated chain.

z.true

An optional vector of cluster assignments considered as the ground-truth clustering of the observations. Useful for simulations.

outputDir

Output directory.

Details

Not really used.