rcophylo_HresP | R Documentation |
This function simulates the evolution of a random host tree with a coevolving random parasite tree.
rcophylo_HresP(
tmax,
nHmax = Inf,
lambda = 1,
mu = 0.5,
K = Inf,
PStartT = 0,
beta = 0,
gamma = 0,
sigma = 0,
nu = 0.2,
kappa = 0,
delta = 0,
thetaS = 1,
thetaE = 1,
prune.extinct = FALSE,
export.format = "cophylogeny",
timestep = 0.001
)
tmax |
a numeric value giving the length of the simulation. |
nHmax |
a numeric value giving the number of host species at which the simulation is stopped. |
lambda |
a numeric value giving the host speciation rate. |
mu |
a numeric value giving the host extinction rate. |
K |
a numeric value giving the carrying capacity for the host species. |
PStartT |
a numeric value within the range of tmax giving the time of parasite invasion |
beta |
a numeric value giving the baseline parasite host shift rate. |
gamma |
a numeric value giving the dependency of host shift success on phylogenetic distance between the old and the new host. |
sigma |
a numeric value determining how successful host shift are when
the new host is already infected by a parasite. Specifically, the
probability of host shift success |
nu |
a numeric value giving the parasite extinction rate. |
kappa |
a numeric value giving the parasite speciation rate within hosts. |
delta |
a numeric value giving the probability of lineage loss during co-speciation. delta=0 specifies faithful transmission of the parasites to both new host species, whereas delta=1 specifies that parasites will only be inherited by one daughter host species. |
thetaS |
a numeric value giving the effect of parasite infection on host speciation rate. |
thetaE |
a numeric value giving the effect of parasite infection on host extinction rate. |
prune.extinct |
logical. Determines whether or not to remove all extinct branches. |
export.format |
a string specifying either "cophylogeny" or "raw". Where "cophylogeny" specifies that the output will be exported as class "cophylogeny" (the default). "raw" exports the output as two objects of class "data.frame". |
timestep |
a numeric value giving the time step by which the simulation proceeds. Increase to make the simulation faster or decrease to make it more precise. |
By default, an object of class "cophylogeny" is returned that is a
list of phylo objects (one for the host and one for the parasite), as
specified in the R-package "ape". If the argument export.format
is
set to "raw" the function returns a list of dataframes containing
information on all the branches in the trees. (These dataframes are what
the function uses internally.)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.