Description Usage Arguments Examples
This function creates a cluster plot of the cluster data point on the first two axes of a principal component analysis. An ellipsoid-hull is fitted round each cluster.
1 2 3 | plot_cluster(data, model, xLabel = "Component 1", yLabel
= "Component 2", pca_function = princomp,
ellipse_quantile = 1, segment_names = NULL)
|
data |
a data frame to be used in clustering |
model |
a cluster model of class kmeans or Mclust |
xLabel |
x-axis label |
yLabel |
y-axis label |
pca_function |
The method for calculating principal components. Must be either princomp or prcomp |
ellipse_quantile |
The quantile for plotting ellipsoids around clusters. For a value of 1, the ellipsoid will be an ellipsoid-hull, i.e. all points will be included. |
segment_names |
Character vector with cluster names |
1 2 3 4 5 6 7 8 9 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.