Hello I was trying to estimate the weibull model using nls after putting OLS values as the initial inputs to NLS. I tried multiple times but still i m getting the same error of Error in nlsModel(formula, mf, start, wts) : singular gradient matrix at initial parameter estimates.
The Program is as below > vel <- c(1,2,3,4,5,6,7,8,9,10,11,12,13,14) > df <- data.frame(conc, vel) > df conc vel 1 0.077 1 2 0.328 2 3 0.882 3 4 1.195 4 5 1.884 5 6 3.577 6 7 6.549 7 8 13.000 8 9 33.690 9 10 52.220 10 11 90.140 11 12 166.050 12 13 233.620 13 14 346.890 14 > plot(df$vel, df$conc) > para0.st <- c(K=450, + alpha=0.054,beta=3.398 ) > fit0 <- nls( + conc~ K-(K*exp(-(vel/alpha)^beta)), df, start= para0.st,trace=T) Error in nlsModel(formula, mf, start, wts) : singular gradient matrix at initial parameter estimates I will be highly thankful if some one can please let me know where is the mistake as i m unable to trace it. Thanks Ruchita On Wed, Dec 16, 2009 at 3:18 PM, ruchita gupta <ruchitarg...@gmail.com>wrote: > Hello > > After performing NLS estimates for some sigmoid model(like logistic growth > model and Gompertz growth models), how can we get the RMSE(root mean square > error) and MAPE(mean absolute percentage error) in R statistical tool for > comparison between two models > > Thanks > Ruchita > [[alternative HTML version deleted]] ______________________________________________ R-help@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.