build_coal_tree.structured | R Documentation |
Generate a Newick string representation of a tree corresponding to a realisation of a structured,linage-based coalescent process. Note: the topology is RANDOM, If you wish for the topology to be consistent, use set.seed before calling this function.
build_coal_tree.structured(
sampling_times,
coalescent_times,
leaf_colours,
coalescent_colours,
div_times,
div_events,
div_from
)
sampling_times |
times of leaves. |
coalescent_times |
times of coalescent events / internal nodes. |
leaf_colours |
leaf colouring |
coalescent_colours |
a numeric vector where number at j-th position indicates that the j-th coalescent event corresponds to j-th lineage. |
div_times |
times of lineage divergence events. |
div_events |
a numeric vector where number at j-th position indicates that the j-th divergence time corresponds to j-th lineage |
div_from |
numeric vector identifying the parent of the j-th diverging lineage |
a list with the Newick string corresponding to the tree, and a list of leaf colouring assignments
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.