MorphyTreeLength {TreeSearch} | R Documentation |
Calculate parsimony score from Morphy object
Description
This function must be passed a valid Morphy object, or R may crash.
For most users, the function TreeLength()
will be more appropriate.
Usage
MorphyTreeLength(tree, morphyObj)
MorphyLength(
parent,
child,
morphyObj,
inPostorder = FALSE,
nTaxa = mpl_get_numtaxa(morphyObj)
)
GetMorphyLength(parentOf, leftChild, rightChild, morphyObj)
C_MorphyLength(parentOf, leftChild, rightChild, morphyObj)
Arguments
tree |
A tree of class |
morphyObj |
Object of class |
parent |
Integer vector corresponding to the first column of the edge
matrix of a tree of class |
child |
Integer vector corresponding to the second column of the edge
matrix of a tree of class |
parentOf |
For each node, numbered in postorder, the number of its parent node. |
leftChild |
For each internal node, numbered in postorder, the number of its left child node or tip. |
rightChild |
For each internal node, numbered in postorder, the number of its right child node or tip. |
Value
MorphyTreeLength()
returns the length of the tree,
after applying weighting.
Functions
-
MorphyLength()
: Faster function that requires internal tree parameters. Node numbering must increase monotonically away from root. -
GetMorphyLength()
: Fastest function that requires internal tree parameters -
C_MorphyLength()
: Direct call to C function. Use with caution.
Author(s)
Martin R. Smith
See Also
PhyDat2Morphy
Other tree scoring:
CharacterLength()
,
IWScore()
,
LengthAdded()
,
MinimumLength()
,
TaxonInfluence()
Other tree scoring:
CharacterLength()
,
IWScore()
,
LengthAdded()
,
MinimumLength()
,
TaxonInfluence()