0

I am using the "ape" package to run a phylogenetic gls, but I am stumped by an error message: could not find function "gls". Does anyone please know how to resolve this? Thank you.

tree <- tree.primates 
bm.prim <- corBrownian(phy=tree) 
XY <- data.frame(Y, X) 
summary(gls(Y ~ X, correlation=corBrownian(phy=tree), data=XY)) 
maRtin
  • 6,336
  • 11
  • 43
  • 66
GTC
  • 3
  • 1
  • 4

1 Answers1

0

ape does not have a gls function. You'll need to load a package that has the implementation you want, probably nlme, though apparently a package called QTLRel has one as well.

Here are my search results on rdocumentation.org which is where I found the packages that have gls functions.

Gregor Thomas
  • 136,190
  • 20
  • 167
  • 294