create_clusters: Create clusters

Description Usage Arguments Value Examples

View source: R/clusters.R

Description

Create clusters

Usage

1
2
3
4
5
create_clusters(
  tree,
  N_clusters,
  method = c("monophyletic", "paraphyletic", "uniform")
)

Arguments

tree

tree whose tips must be clustered.

N_clusters

number of clusters.

method

method to create clusters among "monophyletic", "paraphyletic" and "uniform".

Value

The belonging of each tip to a cluster as a named integer.

Examples

1
2
3
4
5
tree <- ape::rtree(10)
N <- 3
plot(tree)
create_clusters(tree, N)
create_clusters(tree, N, method = "paraphyletic")

abichat/zazou documentation built on Sept. 8, 2021, 6:53 a.m.