.BG
.FN mhtree
.TL
Classification Tree for Model-based Gaussian hierarchical clustering.
.SH DESCRIPTION
Determines a classification tree for agglomerative hierarchical clustering 
using criteria based on 
parameterizations of Gaussian mixture models that reflect the underlying
geometry of the resulting clusters.
.CS
mhtree(data, modelid, partition, min.clusters = 1, verbose = F, ...)
.PP
.RA
.AG data
matrix of observations.
.OA
.AG modelid
An integer specifying a parameterization of the MVN covariance matrix defined 
by volume, shape and orientation charactertistics of the underlying clusters. 
The allowed values or `model' and their interpretation are as follows:
`"EI"' : uniform spherical, `"VI"' : spherical, `"EEE"' : uniform variance, 
`"VVV"' : unconstrained  variance, `"EFV"' : fixed (user supplied)
uniform volume, `"VFV"' : fixed (user supplied) shape.
.AG partition
initial classification of the data. The default puts every observation in a
singleton cluster.
.AG min.clusters
minimum number of clusters desired. The default is to carry out agglomerative
hierarchical clustering until termination, that is, until all observations
belong to a single group.
.AG verbose
A logical variable specifying printing of the model type when set to `T'.
.AG ...
Allows users to specify the required `shape' parameter for the two fixed
shape models `"EFV"' and `"VFV"', and to change default parameters that are 
used in the algorithms underlying some models.
.RT
an object of class `"mhtree"', which consists of a classification tree with
attributes giving other information relating to the clustering process.
.SH NOTES
Only the six models illustrated in the example below are supported at present.
These correspond to the models discussed in the Banfield and Raftery 
reference.
.br
It may be desirable to transform the data in some way before attempting to 
partition it into clusters.
.br 
Different permuations of the data may produce different classifications,
because `mhtree' resolves ties in a way that is dependent on the order of the
observations, and because values of criterion that are close may change enough
to affect the choice of merge pairs in a given stage.
.SH REFERENCES
J. D. Banfield and A. E. Raftery, Model-based Gaussian and non-Gaussian
Clustering, \fIBiometrics, \fR49:803-821 (September 1993).

C. Fraley, Algorithms for Model-based Gaussian Hierarchical Clustering,
\fISIAM Journal on Scientific Computing, \fR20:270-281 (1998).
.SA
`mhclass', `awe', `partuniq'
.EX
> data <- matrix(aperm(iris, c(1,3,2)), 150, 4)

# Uniform spherical (Ward's method).
> mhtree(data, modelid = "EI")

# Spherical, varying sizes (default).
> mhtree(data)
> mhtree(data, modelid = "VI")

# Uniform variance.
> mhtree(data, modelid = "EEE")

# Unconstrained variance.
> mhtree(data, modelid = "VVV")

# Fixed shape and uniform volume.
> shape <- runif(ncol(data))
> mhtree(data, modelid = "EFV", shape = shape)

# Fixed shape.
> shape <- runif(ncol(data))
> mhtree(data, modelid = "VFV", shape = shape)

.KW clustering
.WR

