V. Ancestral Reconstruction with Maximum Likelihood on Discrete Traits in R

EditEdit InfoInfo TalkTalk
Search:    
Primary Contact(s) Created Required Software
Rich Glor 9 March 2009 [WWW]R
Example Datafile Prerequisites
See Introduction R for Phylogenetics parts I, II, III, and IV

Introduction|I. Getting Started|II. Tree Basics|III. Loading Character Data|IV. Testing Phylogenetic Signal|V. Ancestral Reconstruction|VI. Testing Patterns

We can use the ace function of ape to reconstruct ancestral character states using maximum likelihood.

ace(micro, anolisComparativeTree, type="discrete") -> anolisMicro

To view the results of this analysis we have two choices. One option is to look at the raw output:

anolisMicro

Another option is to view the marginal likelihood values on the tree:

plot(anolisComparativeTree, show.node.label=FALSE, cex=0.4) 
nodelabels(pie=anolisMicro$lik.anc, cex=0.5)

NOTE: An important warning is necessary here. The ace function often fails to properly reconstruct ancestral character states. This is certainly true when you observe negative marginal likelihood values in the lik.anc portion of your ace output. Some other error messages may be ignored, but negative marginal likelihoods should not be ignored. Because of this problem, it is not advisable to use R for ancestral reconstruction at this point in time for the purposes of publication. Instead, the ancestral reconstruction algorithms in R should be used strictly for simple visualization and experimentation until the likelihood-fitting functions of ace can be improved.


Continue to part VI: Testing Temporal Patterns of Character Evolution in R
This is a Wiki Spot wiki. Wiki Spot is a non-profit organization that helps communities collaborate via wikis.