R: Generate Comprehensive Trees.

gen.equal.star.anc.dec {phyclust} | R Documentation

## Generate Comprehensive Trees.

### Description

Generate comprehensive trees for simulation studies.

### Usage

    gen.equal.star.anc.dec(K, N.K, rate.f = 0.5)

### Arguments

`K` | number of clusters, K.
`N.K` | number of sequences for each cluster, a vector with length `K`.
`rate.f` | r_f, growth rate ratio of ancestral and descendent trees.

### Details

These functions generates an ancestral tree in K tips and generates descendent trees according to `N.K` tips. All trees, ancestral and descendent, are coerced to star shapes and scaled their heights to fit the ratio `rate.f`, and the final tree has total height 1. The returns are stored in a list, and the final tree is stored with a name `equal.star`.

### Value

A list contains all information of generation and results including:

`'K'` | number of clusters.
`'N.K` | number of sequences for each cluster.
`'rate.f'` | r_f, growth rate ratio of ancestral and descendent trees.
`'anc'` | an ancestral tree.
`'dec'` | all descendent trees.
`'equalstar'` | a tree that descendants are equal star trees.

### Author(s)

Wei-Chen Chen wccsnow@gmail.com

### References

Phylogenetic Clustering Website: https://snoweye.github.io/phyclust/

### See Also

`gen.unit.K`.

### Examples

    ## Not run:
    library(phyclust, quiet = TRUE)

    set.seed(1234)
    tree.K <- gen.equal.star.anc.dec(6, rep(3:5, 2),
                                     rate.f = 0.7)
    X.class <- as.numeric(gsub("d(.).(.)", "\\1",
                               tree.K$equal.star$tip.label))

    # Plot results
    plotnj(tree.K$equal.star, X.class, type = "p",
           edge.width.class = 2, main = "equal.star")
    axis(1)

    ## End(Not run)

[Package phyclust version 0.1-30 Index]