reattach_point {ddtlcm} | R Documentation |
Attach a subtree to a given DDT at a randomly selected location
Description
Attach a subtree to a given DDT at a randomly selected location
Usage
reattach_point(tree_kept, c, c_order = 1, theta = 0, alpha = 0)
Arguments
tree_kept |
the tree to be attached to |
c |
hyparameter of divergence function a(t) |
c_order |
equals 1 (default) or 2 to choose divergence function
|
alpha , theta |
hyparameter of branching probability a(t) Gamma(m-alpha) / Gamma(m+1+theta) For DDT, alpha = theta = 0. For general multifurcating tree from a Pitman-Yor process, specify positive values to alpha and theta. It is, however, recommended using alpha = theta = 0 in inference because multifurcating trees have not been tested rigorously. |
Value
a list of the following objects:
div_time
a numeric value of newly sampled divergence time. Between 0 and 1.
root_node
a character. Label of the root node of
tree_kept
.root_child
a character. Label of the child node of the root of
tree_kept
.div_dist_to_root_child
a N-vector with integer entries from 1, ..., K. The initial values for individual class assignments.
See Also
Other sample trees:
attach_subtree()
,
random_detach_subtree()