[R] custom loss function + nonlinear models

Kjetil Brinchmann Halvorsen kjetil at acelerate.com
Mon Apr 4 23:29:05 CEST 2005


Christian Mora wrote:

>Hi all;
>
>I'm trying to fit a reparameterization of the
>assymptotic regression model as that shown in
>Ratkowsky (1990) page 96. 
>
>Y~y1+(((y2-y1)*(1-((y2-y3)/(y3-y1))^(2*(X-x1)/(x2-x1))))/(1-((y2-y3)/(y3-y1))^2))
>
>where y1,y2,y3 are expected-values for X=x1, X=x2, and
>X=average(x1,x2), respectively.
>
>I tried first with Statistica v7 by LS and
>Gauss-Newton algorithm without success (no
>convergence: predictors are redundant....). Then I
>tried with the option CUSTOM LOSS FUNCTION and several
>algorithms like Quasi-Newton, Simplex, Hookes-Jeeves,
>among others. In all these cases the model converged
>to some values for the parameters in it.
>
>My question is (after searching the help pages) : Is
>there such a thing implemented in R or can it be
>easily implemented? In other words, is it possible to
>define which loss function to use and the algorithm to
>find the parameters estimates? 
>
>Thanks
>Christian
>
>______________________________________________
>R-help at stat.math.ethz.ch mailing list
>https://stat.ethz.ch/mailman/listinfo/r-help
>PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
>
>
>
>  
>
try directly with optim()

Kjetil

-- 

Kjetil Halvorsen.

Peace is the most effective weapon of mass construction.
               --  Mahdi Elmandjra




-- 
Internal Virus Database is out-of-date.
Checked by AVG Anti-Virus.




More information about the R-help mailing list