as.vector.phylo {Rtropical} | R Documentation |
Vectorize a Phylogenetic Tree
Description
Computes the cophenetic distance and outputs them in a vector
of a phylogenetic tree in phylo
object
Usage
## S3 method for class 'phylo'
as.vector(x, mode = "any")
Arguments
x |
A object of class phylo |
mode |
The same as |
Value
A vector with its elements the distance between two leaves of the tree.
Examples
library(ape)
tree <- rcoal(5)
tree_vec <- as.vector(tree)
[Package Rtropical version 1.2.1 Index]