plotDensityClusVisu {ClusVis}R Documentation

Function for visualizing the clustering results

Description

Function for visualizing the clustering results

Usage

plotDensityClusVisu(res, dim = c(1, 2), threshold = 0.95,
  add.obs = FALSE, positionlegend = "topright", xlim = NULL,
  ylim = NULL, colset = c("darkorange1", "dodgerblue2", "black",
  "chartreuse2", "darkorchid2", "gold2", "deeppink2", "deepskyblue1",
  "firebrick2", "cyan1", "red", "yellow"))

Arguments

res

object return by function clusvis or clusvis

dim

numeric. This vector of size two choose the axes to represent.

threshold

numeric. It contains the thersholds used for computing the level curves.

add.obs

boolean. If TRUE, coordinnates of the observations are plotted.

positionlegend

character. It specifies the legend location.

xlim

numeric. It specifies the range of x-axis.

ylim

numeric. It specifies the range of y-axis.

colset

character. It specifies the colors of the observations per class.

Examples

## Not run: 
 # Package loading
 require(Rmixmod)

 # Data loading (categorical data)
 data("congress")
 # Model-based clustering with 4 components
 set.seed(123)
 res <- mixmodCluster(congress[,-1], 4, strategy = mixmodStrategy(nbTryInInit = 500, nbTry=25))

 # Inference of the parameters used for results visualization
 # (specific for Rmixmod results)
 # It is better because probabilities of classification are generated
 # by using the model parameters
 resvisu <- clusvisMixmod(res)

 # Component interpretation graph
 plotDensityClusVisu(resvisu)

 # Scatter-plot of the observation memberships
 plotDensityClusVisu(resvisu,  add.obs = TRUE)

## End(Not run)

[Package ClusVis version 1.2.0 Index]