Learn R Programming

phyloregion (version 1.0.2)

select_linkage: Cluster algorithm selection and validation

Description

This function contrasts different hierarchical clustering algorithms on the phylogenetic beta diversity matrix for degree of data distortion using Sokal & Rohlf<U+2019>s (1962) cophenetic correlation coefficient.

Usage

select_linkage(x)

Arguments

x

a numeric matrix, data frame or "dist" object.

Value

  • A numeric value corresponding to the good clustering algorithm for the distance matrix

  • If plot = TRUE, a barplot of cophenetic correlation for all the clustering algorithms is drawn.

References

Sokal, R.R. & Rohlf, F.J. (1962) The comparison of dendrograms by objective methods. Taxon 11: 33<U+2013>40.

Examples

Run this code
# NOT RUN {
data(africa)
tree <- africa$phylo
bc <- beta_diss(africa$comm)
y <- select_linkage(bc[[1]])
barplot(y, horiz = TRUE, las = 1)

# }

Run the code above in your browser using DataLab