Learn R Programming

phytools (version 2.5-2)

phyl.pairedttest: Phylogenetic paired t-test

Description

Phylogenetic paired t-test following Lindenfors et al. (2010).

Usage

phyl.pairedttest(tree, x1, x2=NULL, se1=NULL, se2=NULL, lambda=1.0, h0=0.0,
   fixed=FALSE, ...)

Arguments

Value

An object of class "phyl.pairedttest" with the following elements:

dbar

phylogenetic mean difference.

se

standard error of dbar.

sig2

estimated evolutionary variance (of the difference).

lambda

fitted (or fixed) value of λ.

logL

log-likelihood of the fitted model.

t.dbar

t-value ((dbar-h0)/se where se is computed from the Hessian).

P.dbar

P-value.

df

the degrees of freedom.

h0

the null hypothesis that was tested.

Details

This function conducts a phylogenetic paired t-test, roughly following Lindenfors et al. (2010).

This is not a phylogenetic ANOVA, in which we want to compare the means of different sets of species on the tree. Instead, we are interested in the difference between two characters, or two measures of a character within a species, and we want to know if this difference is significantly different from zero controlling for the phylogenetic non-independence of species.

Likelihood optimization is performed using optim with method="L-BFGS-B" with box constraints on λ (0,1).

References

Lindenfors, P., L. J. Revell, and C. L. Nunn (2010) Sexual dimorphism in primate aerobic capacity: A phylogenetic test. J. Evol. Biol., 23, 1183-1194.

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