lineage: Find the ancestors of a node

View source: R/tree_manipulation.R

lineageR Documentation

Find the ancestors of a node

Description

Find the ancestors of a node

Usage

lineage(x, ...)

## S3 method for class 'Strata'
lineage(x, id = x@focal_species, type = "name", use_name = TRUE, ...)

## S3 method for class 'phylo'
lineage(x, id, use_name = FALSE, type = "auto", ...)

## S3 method for class 'phylo'
tree_size(x)

Arguments

x

phylo object

...

Arguments passed on to lineage.phylo

id

A single name or index

type

id type: ['name', 'index', 'auto']

use_name

Should names be used rather than internal ids

Examples

data(atree)
lineage(atree, 't1')
lineage(atree, 1)

arendsee/phylostratr documentation built on Dec. 31, 2022, 10:22 a.m.