tidytree (version 0.4.6)

ancestor: ancestor

Description

access ancestor data

Usage

ancestor(.data, .node, ...)

# S3 method for tbl_tree ancestor(.data, .node, ...)

Value

ancestor data

Arguments

.data

phylo or tbl_tree object

.node

node number

...

additional parameters

Author

Guangchuang Yu

Examples

Run this code
library(ape)
tree <- rtree(4)
x <- as_tibble(tree)
ancestor(x, 3)

Run the code above in your browser using DataLab