Re: [R] ape comparative analysis query

From: Simon Blomberg <simonb_at_cres10.anu.edu.au>
Date: Thu 11 May 2006 - 12:02:28 EST

Chris Knight wrote:
>
> This raises various questions:
>
> 1) Was I misleading myself that my independent contrasts were valid in
> the first place?
>
I think partly. Independent contrasts were designed for data for tip taxa only, not ancestral state data. One of the steps in the algorithm requires a correction to account for the fact that ordinarily the values for traits at nodes are estimated and not known, basically lengthening the branch length to that node by a certain amount (See Felsenstein's original paper). If you have known ancestral states, then you should not make this correction.

> 2) What is it, if anything, about the root taxon that causes this issue,
> given that other taxa also have zero branch lengths?
>
When converting a tree to a correlation matrix for use in GLS or GEE, the Brownian motion assumption implies that the covariances among taxa are represented by their shared branch length from the root, and the height of each terminal taxon is equal to the variance of the trait for that taxon. If the tree is ultrametric, then the variances are equal. In your case, the root has zero covariance with each taxon, and zero variance. Now, the error in the gls call is caused by a division by zero in the calculation of the correlation matrix, because the root has zero variance. try:

vcv.phylo(tree)
vcv.phylo(tree, cor=TRUE)

> 3) Is there any way of getting around this and including data on the
> root taxon, or am I better off just dropping it (ultimately I want to
> work with much larger trees (up to tens of thousands of taxa) where that
> one piece of information will become relatively less important)
>
I'm surprised that you have known values for the root data. Are you sure that the root taxon is not actually an outgroup? If so, it will have some branch length (variance), and the model should fit OK.

HTH, Simon.

> Any help very much appreciated,
>
> Chris
>
> I'm working with ape 1.8-2 in R 2.1.1 under ubuntu 'Breezy' linux
> (unfortunately 2.1.1 is the latest easily available in breezy)
>
>



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Thu May 11 12:10:02 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Fri 12 May 2006 - 00:10:04 EST.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.