Skip to content
Back to formatted view

Raw Message

Message-ID: <D736F454355006429DA41754A53FFDBB43CD1107@exmbx06-cdc.nexus.csiro.au>
Date: 2015-05-27T09:06:34Z
From: Onoriode.Coast at csiro.au
Subject: Estimating Four Parameters with nls in R

Hello all!

I am trying to estimate four parameters of a model (mu, sigma, theta and lambda) for a subset of data (snapshot given below). I have tried to do this using the nls package in R but I kept getting error messages (Error in numericDeriv(form[[3L]], names(ind), env) :  --AND-- Missing value or an infinity produced when evaluating the model). Please have a look at my code and tell, if you can, how I might get it to work. The data has five levels of "WP" (0, -0.4, -0.8, -1.2 and -1.6).

Mod1<-nls(1-germ~exp(-1*((WP-(theta/time)-mu)/sigma)^lambda),start=c(mu=-3,theta=3,sigma=3,lambda=-1),data=ht)

WP

time

germ

0

1.333333

0

0

1.416667

0

0

1.5

0.04

0

1.583333

0.04

0

2.083333

0.08

0

2.166667

0.16

0

2.25

0.24

0

2.333333

0.36

0

2.416667

0.6

0

2.5

0.64

0

2.583333

0.64

0

2.666667

0.72

0

2.916667

1

.
.
.
-1.6

2.916667

0

-1.6

3.166667

0

-1.6

3.666667

0

-1.6

4.166667

0

-1.6

4.666667

0

-1.6

5.166667

0

-1.6

5.666667

0

-1.6

7.666667

0

-1.6

9.666667

0

-1.6

12.66667

0

-1.6

19.66667

0



Dr Onoriode Coast
Postdoctoral Fellow
Agriculture Flagship
CSIRO
E onoriode.coast at csiro.au


	[[alternative HTML version deleted]]