1

Does anyone know of a package or method in R of carrying out a MANOVA whilst controlling for phylogenetic non-independence?

Thank you!

SlowLoris
  • 995
  • 6
  • 28
Sarah
  • 789
  • 3
  • 12
  • 29

1 Answers1

4

sos package is your friend:

library('sos')
findFn('phylogenetic MANOVA')

seems like geiger package and more precisely aov.phylo performs phylogenetic ANOVA or MANOVA.

Here an example from the help :

library(geiger)
geo=get(data(geospiza))
dat=geo$dat
d1=dat[,1]
grp<-as.factor(c(rep(0, 7), rep(1, 6)))
names(grp)=rownames(dat)

## MANOVA
x=aov.phylo(dat~grp, geo$phy, nsim=50, test="Wilks")
Multivariate Analysis of Variance Table

Response: dat
          Df   Wilks approx-F num-Df den-Df   Pr(>F) Pr(phy)
group      1 0.27872   3.6229      5      7 0.061584   0.549
Residuals 11      
agstudy
  • 119,832
  • 17
  • 199
  • 261
  • Thank you! What a great package sos is - I haven't come across that before! With regards to geiger, do you have any recommendations on the test to pick? I know the example uses Wilks, but base R's MANOVA uses Pillai which is an option, and other options seem to be "Hotelling-Lawley" and "Roy"... – Sarah Jun 03 '13 at 10:05
  • Ah, the vignettes say: "The summary.manova method uses a multivariate test statistic for the summary table. Wilks' statistic is most popular in the literature, but the default Pillai–Bartlett statistic is recommended by Hand and Taylor (1987)." Hand, D. J. and Taylor, C. C. (1987) Multivariate Analysis of Variance and Repeated Measures. Chapman and Hall. – Sarah Jun 03 '13 at 10:20
  • Is there a way to do the same for continuous data? This only works for categorical independent variables.. – Sarah Jun 03 '13 at 12:20