modalclust {modalclust} | R Documentation |
Implementation of method and examples of David B. Dahl's 2008 paper entitled "Modal Clustering in a Class of Product Partition Models". See reference below.
modalclust(data, model = c("nn", "bb", "gg", "spread")[1], mass = 1, param = c(0.1, 0.1, 1), use.DP.prior = TRUE) modalclust.gui()
data |
A numeric vector of univariate sufficient statistics of the observations. |
model |
A character vector of length one indicating the desired model from which the modal clustering is desired. nn , bb , and gg indicate the Normal-Normal, Binomial-Beta, and Gamma-Gamma models in Section 4 of Dahl (2008). spread indicates the reparametrization of the Gamma-Gamma model of Section 6.3 of Dahl (2008). |
mass |
A numeric vector of length one giving the mass parameter for the Dirichlet process prior (if use.DP.prior is true ) or the value for lambda in the second cohesion h(S) of Dahl (2008) (if use.DP.prior is false ). |
param |
A numeric vector of length three whose elements depend on the particular model selected. See Dahl (2008) for complete details.
For the Normal-Normal model (nn ), the elements are the variance of mixture component, the mean of centering distribution, and the variance of centering distribution.
For the Binomial-Beta model (bb ), the elements are the number of trials in the mixture component, the first shape parameter of the centering distribution, and the second shape parameter of centering distribution.
For the Gamma-Gamma model (gg ), the elements are the shape of the mixture component, the shape parameter of the centering distribution, and the scale of the centering distribution.
For the spread model (spread ), the elements are the degrees of freedom, the expectation of the prior distribution on the variance, and the variance of the prior distribution on the variance.
|
use.DP.prior |
A logical vector of length one indicating how to interpret the mass argument. |
This method finds the modal clustering for several models in a class of univariate product partition models. Complete details on the method and models are available in Dahl (2008).
The modal clustering as represented by a vector of cluster labels.
David Dahl dahl@stat.tamu.edu
D. B. Dahl (2008), Modal Clustering in a Class of Product Partition Models, submitted. Complete paper at http://www.stat.tamu.edu/~dahl/papers/modalclust/dahl-2008.pdf.