Learn R Programming

phytools (version 2.5-2)

fitcontMk: Fits binary discrete character evolution model where the transition rate varies as a function of a continuous trait

Description

Fits a model where the rate of evolution of a binary trait depends on the value of a continuous character using the discretized diffusion approximation of Boucher & Demery (2016).

Usage

fitcontMk(tree, x, y, model="sigmoidal", ...)

Value

An object of class "fitcontMk".

Arguments

tree

object of class "phylo".

x

binary discrete character, normally in the form of a factor or character vector.

y

continuous character data in a vector.

model

functional form describing the relationship between the value of the continuous trait and the binary discrete character transition rate. Presently the only option is model="sigmoidal".

...

optional arguments.

Author

Liam Revell liam.revell@umb.edu

Details

fitcontMk uses the discretized diffusion approximation of Boucher & Demery (2016) to fit a model where the rate of evolution of a binary trait (in x) depends on the state of a continuous trait (in y), where the discrete and continuous character are modeled jointly. In some ways this is philosophically equivalent to the binary trait correlation method of Pagel (1994), but where one of the traits is continuously-valued.

Optional arguments include parallel (whether to distribute matrix exponentiation across nodes, which defaults to parallel=TRUE), levs (the number of levels for the discrete approximation, which defaults to levs=100), and plot_model (a logical indicating whether or not to graph the model while optimizing (which defaults to plot_model=FALSE).

References

Boucher, F. C., and V. Demery (2016) Inferring bounded evolution in phenotypic characters from phylogenetic comparative data. Systematic Biology, 65, 651-661.

Pagel, M. (1994) Detecting correlated evolution on phylogenies: A general method for the comparative analysis of discrete characters. Proceedings of the Royal Society B, 255, 37-45.

Revell, L. J. (2024) phytools 2.0: an updated R ecosystem for phylogenetic comparative methods (and other things). PeerJ, 12, e16505.

See Also

bounded_bm, brownie.lite, fitMk, fitmultiBM, fitPagel