extract.enumerate_parsimony: Extract the result of 'enumerate_parsimony' at a node.

View source: R/parsimonyNumber.R

extract.enumerate_parsimonyR Documentation

Extract the result of enumerate_parsimony at a node.

Description

extract.enumerate_parsimony returns a matrix containing all the possible regime allocations for the nodes of a given subtree.

Usage

## S3 method for class 'enumerate_parsimony'
extract(
  x,
  node = attr(x$allocations, "ntaxa") + 1,
  what = c("solutions", "number", "cost"),
  ...
)

Arguments

x

an object of class "enumerate_parsimony", result of function enumerate_parsimony.

node

the node where to retrieve the parsimony number. Default to the root of the tree.

what

the quantity to retrieve. Either "solutions" for the full solutions, "number" for the number of solutions, or "cost" for the minimal cost of a solution. Default to "solutions"

...

unused

Value

A matrix with ntaxa + Nnode columns, and as many rows as the number of possible parsimonious reconstructions.

See Also

enumerate_parsimony, plot.enumerate_parsimony


pbastide/PhylogeneticEM documentation built on Feb. 12, 2024, 1:27 a.m.