% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils.R
\name{taxo_path}
\alias{taxo_path}
\title{Get the taxonomic path between two taxa}
\usage{
taxo_path(taxon_a, taxon_b, verbose = FALSE)
}
\arguments{
\item{taxon_a}{A character string giving the first taxon name.}

\item{taxon_b}{A character string giving the second taxon name.}

\item{verbose}{Logical. If \code{TRUE}, prints progress messages. Default \code{FALSE}.}
}
\value{
A data frame of class \code{"taxodist_path"} with columns:
\describe{
\item{\code{node}}{Character. The clade or taxon name at this step.}
\item{\code{depth}}{Integer. The depth of this node in the full lineage of
its side (or the shared lineage for the MRCA).}
\item{\code{direction}}{Character. One of \code{"a"} (ascending from taxon A to
MRCA), \code{"mrca"} (the shared ancestor), or \code{"b"} (descending from MRCA
to taxon B).}
}
Returns \code{NULL} if either taxon cannot be found or if their lineages have no
common ancestor.
}
\description{
Returns the full node-by-node path from one taxon up to their most recent
common ancestor (MRCA) and back down to the other taxon. The result is a
data frame with one row per node, making it easy to inspect, filter, or
pipe into other functions.
}
\examples{
\donttest{
taxo_path("Tyrannosaurus", "Velociraptor")
taxo_path("Tyrannosaurus", "Homo")
}
}
\seealso{
\code{\link[=mrca]{mrca()}}, \code{\link[=shared_clades]{shared_clades()}}, \code{\link[=compare_lineages]{compare_lineages()}}
}
