[R] problem with nls starting values
Bert Gunter
gunter.berton at gene.com
Thu Sep 27 22:16:01 CEST 2012
On Thu, Sep 27, 2012 at 12:43 PM, Benedikt Gehr
<benedikt.gehr at ieu.uzh.ch> wrote:
> now I feel very silly! I swear I was trying this for a long time and it
> didn't work. Now that I closed R and restarted it it works also on my
> machine.
>
> So is the only problem that my model is overparametrized with the data I
> have?
Probably.
> however shouldn't it be possible to fit an nls to these data?
(Obviously) no.
I suggest you do a little reading up on optimization.
Over-parameterization creates high dimensional ridges.
-- Bert
>
> thanks for the help
>
> Am 27.09.2012 21:27, schrieb Berend Hasselman:
>>
>> y_val<-115-118*exp(-0.12*(seq(1,100)+rnorm(100,0,0.8)))
>> >x_val<-seq(1:100)
>> >plot(y_val~x_val)
>>
>> > >summary(mod1<-nls(y_val~a-b*exp(-c*x_val),start=list(a=115,b=118,c=0.12)))
>> >
>
>
> --
> Benedikt Gehr
> Ph.D. Student
>
> Institute of Evolutionary Biology and Environmental Studies
> University of Zurich
> Winterthurerstrasse 190
> CH-8057 Zurich
>
> Office 13 J 36b
> Phone: +41 (0)44 635 49 72
> http://www.ieu.uzh.ch/staff/phd/gehr.html
>
> ______________________________________________
> R-help at r-project.org 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.
--
Bert Gunter
Genentech Nonclinical Biostatistics
Internal Contact Info:
Phone: 467-7374
Website:
http://pharmadevelopment.roche.com/index/pdb/pdb-functional-groups/pdb-biostatistics/pdb-ncb-home.htm
More information about the R-help
mailing list