| KeptPaths {TreeTools} | R Documentation |
Lists which paths present in a master tree are present when leaves are dropped.
KeptPaths(paths, keptVerts, all = TRUE) ## S3 method for class 'data.frame' KeptPaths(paths, keptVerts, all = TRUE) ## S3 method for class 'matrix' KeptPaths(paths, keptVerts, all = TRUE)
paths |
|
keptVerts |
Logical specifying whether each entry is retained in the
reduced tree, perhaps generated using |
all |
Logical: if |
KeptPaths() returns a logical vector specifying whether each path
in paths occurs when keptVerts vertices are retained.
Martin R. Smith (martin.smith@durham.ac.uk)
Other tree manipulation:
AddTip(),
CollapseNode(),
ConsensusWithout(),
DropTip(),
EnforceOutgroup(),
ImposeConstraint(),
KeptVerts(),
LeafLabelInterchange(),
MakeTreeBinary(),
RenumberTips(),
RenumberTree(),
Renumber(),
RootTree(),
SingleTaxonTree(),
SortTree(),
Subtree()
master <- BalancedTree(9) paths <- PathLengths(master) keptTips <- c(1, 5, 7, 9) keptVerts <- KeptVerts(master, keptTips) KeptPaths(paths, keptVerts) paths[KeptPaths(paths, keptVerts, all = FALSE), ]