Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

plot.Mclust

Plotting method for Mclust model-based clustering


Description

Plots for model-based clustering results, such as BIC, classification, uncertainty and density.

Usage

## S3 method for class 'Mclust'
plot(x, what = c("BIC", "classification", "uncertainty", "density"), 
     dimens = NULL, xlab = NULL, ylab = NULL,
     addEllipses = TRUE, main = FALSE, ...)

Arguments

x

Output from Mclust.

what

A string specifying the type of graph requested. Available choices are:

"BIC"

plot of BIC values used for choosing the number of clusters.

"classification" =

a plot showing the clustering. For data in more than two dimensions a pairs plot is produced, followed by a coordinate projection plot using specified dimens. Ellipses corresponding to covariances of mixture components are also drawn if addEllipses = TRUE.

"uncertainty"

a plot of classification uncertainty. For data in more than two dimensions a coordinate projection plot is drawn using specified dimens.

"density"

a plot of estimated density. For data in more than two dimensions a matrix of contours for coordinate projection plot is drawn using specified dimens.

If not specified, in interactive sessions a menu of choices is proposed.

dimens

A vector of integers specifying the dimensions of the coordinate projections in case of "classification", "uncertainty", or "density" plots.

xlab, ylab

Optional labels for the x-axis and the y-axis.

addEllipses

A logical indicating whether or not to add ellipses with axes corresponding to the within-cluster covariances in case of "classification" or "uncertainty" plots.

main

A logical or NULL indicating whether or not to add a title to the plot identifying the type of plot drawn.

...

Other graphics parameters.

Details

For more flexibility in plotting, use mclust1Dplot, mclust2Dplot, surfacePlot, coordProj, or randProj.

See Also

Examples

precipMclust <- Mclust(precip)
plot(precipMclust)

faithfulMclust <- Mclust(faithful)
plot(faithfulMclust)

irisMclust <- Mclust(iris[,-5])
plot(irisMclust)

mclust

Gaussian Mixture Modelling for Model-Based Clustering, Classification, and Density Estimation

v5.4.10
GPL (>= 2)
Authors
Chris Fraley [aut], Adrian E. Raftery [aut] (<https://orcid.org/0000-0002-6589-301X>), Luca Scrucca [aut, cre] (<https://orcid.org/0000-0003-3826-0484>), Thomas Brendan Murphy [ctb] (<https://orcid.org/0000-0002-5668-7046>), Michael Fop [ctb] (<https://orcid.org/0000-0003-3936-2757>)
Initial release
2022-05-20

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.