hcRandomPairs | R Documentation |
Create a hierarchical structure using a random hierarchical partition of the data.
hcRandomPairs(data, seed = NULL, ...)
data |
A numeric matrix or data frame of observations. If a matrix or data frame, rows correspond to observations and columns correspond to variables. |
seed |
Optional single value, interpreted as an integer, specifying the seed for random partition. |
... |
Catches unused arguments in indirect or list calls via |
A numeric two-column matrix in which the ith row gives the minimum index for observations in each of the two clusters merged at the ith stage of a random agglomerative hierarchical clustering.
hc
,
hclass
hcVVV
data <- iris[,1:4]
randPairs <- hcRandomPairs(data)
str(randPairs)
# start model-based clustering from a random partition
mod <- Mclust(data, initialization = list(hcPairs = randPairs))
summary(mod)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.