is_member: Test whether one taxon is nested within another

View source: R/utils.R

is_memberR Documentation

Test whether one taxon is nested within another

Description

Returns TRUE if taxon is a member of clade — i.e., if the clade name appears in the taxon's lineage.

Usage

is_member(taxon, clade, verbose = FALSE)

Arguments

taxon

A character string giving the taxon name to test.

clade

A character string giving the clade name to test membership in.

verbose

Logical. If TRUE, prints progress messages. Default FALSE.

Value

A logical value, or NULL if the taxon cannot be found.

Examples


is_member("Tyrannosaurus", "Theropoda")    # TRUE
is_member("Triceratops", "Theropoda")      # FALSE
is_member("Homo", "Amniota")               # TRUE


taxodist documentation built on May 6, 2026, 1:06 a.m.