View source: R/optCluster-Functions.R
| valPlot | R Documentation |
valPlot displays a plot of the scores for each selected validation measure.
valPlot(x, measures = measureNames(x), legend = TRUE,
legendLoc = "topright", main = NULL, pch = NULL, type = "b",
ask = prod(par("mfcol")) < length(measures) && dev.interactive(), ...)
x |
An object of class |
measures |
Character vector of the names of the validation measures to plot. Any number of choices is allowed. |
legend |
If TRUE, provides a legend. |
legendLoc |
Character string specifying the location of the legend. |
main |
Character string specifying the title of graph. |
pch |
Specifies the plotting characters to use. |
type |
A character string specifying the type of plot. |
ask |
If TRUE, the user is prompted before each plot. |
... |
Additional plotting parameters. |
The the biological homogeneity index (BHI), biological stability index (BSI), Dunn index, and silhouette width measures should all be maximized.
The average proportion of non-overlap (APN), average distance (AD), average distance between means (ADM), figure of merit (FOM), and connectivity measures should all be minimized.
clValid-class, optCluster-class
## This example may take a few minutes to compute
## Obtain Dataset
data(arabid)
## Normalize Data with Respect to Library Size
obj <- t(t(arabid)/colSums(arabid))
## Analysis of Normalized Data using Internal and Stability Validation Measures
norm1 <- optCluster(obj, 2:4, clMethods = "all")
## Plots of Internal and Stability Validation Measures
par(mfrow = c(4,2))
valPlot(norm1)
## Plots of Internal Validation Measures in a Single Figure
par(mfrow = c(2,2))
valPlot(norm1, measure = c("Dunn", "Silhouette", "Connectivity"), legend = FALSE)
plot(0, type="n", axes=FALSE, xlab = "", ylab = "")
legend("center", methodNames(norm1), col=1:9, lty=1:9, pch=paste(c(1:9)),
cex=0.8)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.