The input is a tree and a data file OR a fitted OUwie object. The tree must be of class “phylo” and if simmap=FALSE
must contain the ancestral selective regimes as internal node labels. The data file is a dataframe that must have column entries in the following order: [,1] species names and [,2] their current selective regime. If mserr="known"
then a third column can be added which contains the measurement error for each species. Note that if simmap=TRUE
no data file is needed. The user specifies the simulated parameter values (i.e. \(\alpha\), \(\sigma^2\), \(\theta_0\), \(\theta\)). Assuming two selective regimes, possible models can be specified as follows (Note that this assumes a stationary distribution at the root):
a. Single rate Brownian motion (BM1
): alpha=c(1e-10,1e-10); sigma.sq=c(0.45,0.45); theta0=1.0; theta=c(0,0).
b. Brownian motion with different rate parameters for each state on a tree (BMS
): alpha=c(1e-10,1e-10) sigma.sq=c(0.45,0.90); theta0=1.0; theta=c(0,0).
c. Ornstein Uhlenbeck with a single optimum for all species (OU1
): alpha=c(0.1,0.1); sigma.sq=c(0.9,0.9); theta0=1; theta=c(1.0,1.0).
d. Ornstein Uhlenbeck model that assumes different state means and a single \(\alpha\) and \(\sigma^2\) (OUM
): alpha=c(1.0,1.0); sigma.sq=c(0.45,0.45); theta0=1.0; theta=c(1.0,2.0).
e. Ornstein Uhlenbeck model that assumes different state means and multiple \(\sigma^2\) (OUMV
): alpha=c(1.0,1.0); sigma.sq=c(0.45,0.90); theta0=1.0; theta=c(1.0,2.0).
f. Ornstein Uhlenbeck model that assumes different state means and multiple \(\alpha\) (OUMA
): alpha=c(1.0,0.5); sigma.sq=c(0.45,0.45); theta0=1.0; theta=c(1.0,2.0).
g. Ornstein Uhlenbeck model that assumes different state means and multiple \(\sigma^2\) and \(\alpha\) (OUMVA
): alpha=c(1.0,0.5); sigma.sq=c(0.45,0.9); theta0=1.0; theta=c(1.0,2.0).
With a fitted OUwie model, it just uses the parameters from that, ignoring any alpha, theta, etc. set in the function.