View source: R/bayou-likelihood.R
bayou.lik | R Documentation |
Function for calculating likelihood of an OU model in bayou using the threepoint algorithm
bayou.lik(pars, cache, X, model = "OU")
pars |
A list of parameters to calculate the likelihood |
cache |
A bayou cache object generated using .prepare.ou.univariate |
X |
A named vector giving the tip data |
model |
Parameterization of the OU model. Either "OU", "QG" or "OUrepar". |
This function implements the algorithm of Ho and Ane (2014) implemented
in the package phylolm
for the OUfixedRoot
model. It is faster
than the equivalent pruning algorithm in geiger, and can be used on non-
ultrametric trees (unlike OU.lik, which is based on the pruning algorithm in
geiger).
A list containing:
The log-likelihood value of the fitted OU model.
A vector of estimated optima for each evolutionary regime.
The residuals, i.e., the differences between observed and expected values.
A list of computed values from the three-point algorithm, including necessary likelihood calculations.
The transformed phylogenetic tree with modified branch lengths based on the model parameters.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.