nls error message

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

nls error message

Jim Bouldin

When I try to run the following non-linear regression with  variables
index1 and prl3:

> beta = 4
> nls(index1~beta*(1/prl3),start = list(beta = 4))

I get this error message:

Error in nls(index1 ~ beta * (1/prl3), start = list(beta = 4)) :
  REAL() can only be applied to a 'numeric', not a 'logical'

I've got no clue as to the REAL() to which this is referring.  Any help
appreciated. Thanks in advance.


Jim Bouldin
Research Ecologist
Department of Plant Sciences, UC Davis
Davis CA, 95616
530-554-1740

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: nls error message

Uwe Ligges-3


Jim Bouldin wrote:

> When I try to run the following non-linear regression with  variables
> index1 and prl3:
>
>> beta = 4
>> nls(index1~beta*(1/prl3),start = list(beta = 4))
>
> I get this error message:
>
> Error in nls(index1 ~ beta * (1/prl3), start = list(beta = 4)) :
>   REAL() can only be applied to a 'numeric', not a 'logical'

Please see the posting guide.  For reproducibility, we'd need prl3 and
index1.


> I've got no clue as to the REAL() to which this is referring.  Any help
> appreciated. Thanks in advance.

Try traceback().

Uwe Ligges


>
> Jim Bouldin
> Research Ecologist
> Department of Plant Sciences, UC Davis
> Davis CA, 95616
> 530-554-1740
>
> ______________________________________________
> [hidden email] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.