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
  • 5,700
  • 11
  • 40
  • 65
GTC
  • 3
  • 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
  • 119,032
  • 17
  • 152
  • 277