[R] nlme: gnls with weights and correlation arguments

Ben Bolker ben at zoo.ufl.edu
Tue Nov 26 23:09:57 CET 2002


  Some students of mine are trying to use gnls, the generalized non-linear
least squares function within the nlme library, to study evolutionary
questions where correlations between traits at the species level are
non-independent because of the evolutionary relatedness of the species.  
Specifically, they're using a non-linear function (log(sexual dimorphism)  
~ log(a + b*variation in mating opportunities), an exponential spatial
correlation function that depends on the phylogenetic distance between
species [I hacked the library a little bit to allow one to specify a
distance matrix directly, rather than specifying spatial positions], and a
weight function that covaries as a power of the average body size.

  They are running into trouble when they try to fit models that have both
a non-trivial weights function and a non-trivial correlation function
specified.  We are still exploring the problem, trying different data
sets, etc., to narrow down the problem, but I just thought I would float
it here to see if this fairly vague description sparked any thoughts.  As
I understand it, they get sensible answers without specifying a weights
function, but when using the weights function (which seems justified by
the parameter values estimated), there is severe and somewhat weird
dependence on the starting conditions specified.  It doesn't appear to be
a simple problem of multiple modes or a very flat goodness-of-fit surface.

  (Emmanuel Paradis' ape package is an alternative approach to this 
problem, which we are aware of and may look into, but we'd like to try to 
sort this out if I can.)

  Any thoughts?

  Ben Bolker  


-- 
318 Carr Hall                                bolker at zoo.ufl.edu
Zoology Department, University of Florida    http://www.zoo.ufl.edu/bolker
Box 118525                                   (ph)  352-392-5697
Gainesville, FL 32611-8525                   (fax) 352-392-3704

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list