bears_2param_standard_fast
or a similar ML search function.
get_ML_states(relprobs_matrix, unlist_TF = TRUE)
bears_2param_standard_fast
or a
similar function. The user should specify WHICH matrix in
the results_object -- i.e., scaled conditional
likelihoods on downpass or uppass, or actual marginal
probabilities of ancestral states. (The latter is the
main thing of interest.) This specification is done via
e.g. relprobs_matrix =
results_object$relative_probs_of_each_state_at_branch_top_AT_node_DOWNPASS
.inf_statesvec
The inferred vector of states.
LAGRANGE
seems to do when reporting
ancestral states, also (personal observation, perhaps
imperfect, especially if the scaled conditional
likelihoods and the marginal ancestral state
probabilities turn out to be very close). What is desired
is the marginal ancestral state reconstructions. Most
authors discuss ML ancestral state reconstruction as
being a matter of re-rooting the tree at each node,
yielding the marginal estimate for that node, conditional
on the rest of the tree. However, this procedure assumes
a time-reversible model on both branches and cladogenesis
events, and we have neither in biogeography. Probably,
the solution is just an up-pass from the root,
calculating the probabilities on the forward model and
multiplying by likelihoods from the downpass. However,
this has not yet been implemented.
Felsenstein2004
Matzke_2012_IBS
get_ML_probs
,
bears_2param_standard_fast
,
get_ML_state_indices