Learn R Programming

pdc (version 1.0.3)

mdsPlot: Multidimensional Scaling Plot

Description

Plots a two-dimensional projection to the principal coordinates of all observations. Clusters are shown as polygonal convex hulls of their members.

Usage

mdsPlot (X, labels = NULL, col = "gray")

Arguments

X
A pdclust object.
labels
Optional. A vector of labels for the observations. If NULL, column names of the dataset are used.
col
A vector of colors for polygon shading.

References

Brandmaier, A. M. (2015). pdc: An R Package for Complexity-Based Clustering of Time Series. Journal of Statistical Software, 67(5), 1--23.

See Also

pdclust

Examples

Run this code
data("complex.shapes")
truth <- c(rep("fish",5),rep("bottle",4),rep("glasses",5))
clust <- pdclust(complex.shapes, t=5)
mdsPlot(clust, truth, col=c("lightblue","lightgreen","lightgray"))

Run the code above in your browser using DataLab