[R] NLS "Singular Gradient" Error

Ben Bolker bolker at ufl.edu
Wed Apr 28 17:19:26 CEST 2010


Gabor Grothendieck <ggrothendieck <at> gmail.com> writes:

> 
> What does "no success" mean?
> 
> Some things to try are:
> 
> - since log(1-Ne/No)  is linear in Ne and run an lm(log(1-Ne/No) ~ Ne)
> and then use the implied  values from that or use them as starting
> values,
> 
> - reparameterize a*(b*Ne-T) to aa*Ne + bb and try nls on that
> 
> On Wed, Apr 28, 2010 at 9:13 AM, bsnrh <bsnrh <at> leeds.ac.uk> wrote:
> >
> > Thank you for your reply.
> >
> > The equation is derived from Juliano's chapter in Scheiner and Gurevitch
> > (2001) on Functional Responses.
> >
> > I have tried calling T<-24 and rerunning with no success sadly.

  You should really try the methods I suggested ... you can get
a closed-form expression for the number eaten as a function of the
other parameters using the Lambert W function.  I don't think what
you're doing (with Ne on both sides of the equation) is ever going to
work ...

  Ben Bolker



More information about the R-help mailing list