Learn R Programming

picante (version 1.8.2)

phyEstimate: Phylogenetic estimation of traits for unobserved taxa

Description

Uses phylogenetic ancestral state reconstruction to estimate trait values for unobserved taxa.

Usage

phyEstimate(phy, trait, method="pic", ...)
phyEstimateDisc(phy, trait, best.state=TRUE, cutoff=0.5, ...)

Arguments

phy

phylo object

trait

vector or data.frame containing trait values

method

ancestral state estimation method used by ace (default="pic")

best.state

estimate best-supported trait state for discrete variables? (default=TRUE)

cutoff

support cutoff required to declare a best.state

...

Additional arguments passed to ace

Value

phyEstimate produces a data frame with columns:

est

Estimated trait value

se

Standard error of estimated trait value

phyEstimateDisc produces a data frame with columns:
states 1..N

A column with statistical support is produced for each discrete trait state

estimated.state

If best.state=TRUE, a column with the state with the highest support

estimated.state.support

Statistical support for the state with the highest support

Details

These functions use phylogenetic ancestral state estimation to infer trait values for novel taxa on a phylogenetic tree, for continuous (phyEstimate) and discrete (phyEstimateDisc) traits.

The required input is a phylogenetic tree object plus a vector or data.frame containing estimated trait values for a subset of the taxa in the phylogenetic tree. Trait values for taxa that are present in the tree but not the trait data will be estimated using ancestral state estimation (Garland and Ives 2000). Briefly, for each taxon present in the tree but not the trait data, the phylogeny is rerooted at the most recent common ancestor of the novel taxon and the rest of the phylogeny, and the trait value of the novel taxon is estimated from the reconstructed trait value at the root of the rerooted phylogeny.

For phyEstimateDisc, the state with the highest support will be reported if argument best.state=TRUE. If the best-supported state's support is less than the specified cutoff, no best state is reported and a NA value will be returned.

References

T. Garland Jr., and A.R. Ives. 2000. Using the past to predict the present: confidence intervals for regression equations in phylogenetic comparative methods. American Naturalist 155:346364.

S.W. Kembel, M. Wu, J.A. Eisen, and J.L. Green. 2012. Incorporating 16S gene copy number information improves estimates of microbial diversity and abundance. PLoS Computational Biology 8(10):e1002743.

Examples

Run this code
# NOT RUN {
#generate random phylogeny
randtree <- rcoal(50)
#simulate trait evolution for a subset of taxa on phylogeny
randtraits <- sample(rTraitCont(randtree, sigma=10, root.value=100), 40)
#estimate trait values for "missing" taxa using PIC method
phyEstimate(randtree, randtraits, method="pic")
# }

Run the code above in your browser using DataLab