Description Usage Arguments Value Note Author(s) References See Also Examples

Function `relabel`

implements Algorithm 2 in Matthew Stephens (2000) JRSSB for the posterior allocation probability matrix, minimizing the Kullback-Leibler distance. Step 2 in this algorithm is solved using the Hungarian (Munkres) algorithm to the assignment problem.

1 2 | ```
relabel(probs.mcmc, nIter, nItem, nClust,
RELABEL.THRESHOLD, PRINT = 0, PACKAGE="DIRECT")
``` |

`probs.mcmc` |
A |

`nIter` |
Number of stored MCMC samples. |

`nItem` |
Number of items. |

`nClust` |
Number of inferred clusters. |

`RELABEL.THRESHOLD` |
A positive scalar. Used to determine whether the optimization in the relabeling algorithm has converged. |

`PRINT` |
If TRUE, print intermediate values onto the screen. Used for debugging with small data sets. |

`PACKAGE` |
Not for use. |

Permuted labels for each store MCMC sample are written to file *_mcmc_perms.out, in which each row contains an inferred permutation (relabel) of labels of mixture components.

This function calls a routine written in C, where implementation of Munkres algorithm is adapted from the C code by Dariush Lotfi (June 2008; web download).

Audrey Q. Fu

Fu, A. Q., Russell, S., Bray, S. and Tavare, S. (2013) Bayesian clustering of replicated time-course gene expression data with weak signals. The Annals of Applied Statistics. 7(3) 1334-1361.

Stephens, M. (2000) Dealing with label switching in mixture models. Journal of the Royal Statistical Society, Series B, 62: 795-809.

`DIRECT`

for the complete method.

`DPMCMC`

for the MCMC sampler under the Dirichlet-process prior.

`resampleClusterProb`

for resampling of posterior allocation probability matrix in posterior inference.

1 | ```
## See example for DIRECT.
``` |

DIRECT documentation built on May 1, 2019, 8:08 p.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.