Use the maximum likelihood parameters of the model to simulate trait values on a phylogenetic tree.

simulateTrait(object, tree = NULL)

Arguments

object

an S3 object of class POUMM

tree

a phylo object. If NULL (default) the trait is simulated on the tree, on which the POUMM object has been fit.

Value

a numerical vector containing the simulated trait value for each tip in the tree.

Details

This function is a shortcut to calling rVNodesGivenTreePOUMM, which will map the inferred parameters of the model back to the original POUMM parameters alpha, theta, sigma, sigmae, and g0.

See also