clustPAM: Cluster phylogenetic tree using PAM

Description Usage Arguments Value References Examples

View source: R/ClustTree.R

Description

A function that calculates optimal tree clustering scheme using PAM method given the number of clusters, file directory for a phylogenetic tree or a newick tree character string.

Usage

1
clustPAM(k, file = "", text = NULL)

Arguments

k

A positive integer greater than 1 indicating the number of clusters.

file

A character string indicating the path to the newick tree. Default value is "".

text

A character string of the tree in newick format. Default value is NULL. By default, this is ignored. When this argument is assigned a value, the argument file is ignored.

Value

Returns an S3 object of class PAMclusts with results.

References

Kaufman, L., & Rousseeuw, P. J. (2005). Finding groups in data: An introduction to cluster analysis. Wiley.

Examples

1
2
# Make 6 clusters from a newick tree using PAM
pam <- clustPAM(6, text = NwkTree2)

rainali475/ClustPhy documentation built on Dec. 22, 2021, 12:03 p.m.