Skip to content

France Model

2 messages · Silvano, Sven Garbade

#
Hi,

I need fit the France model :

y = A{1 - exp[-b(t-T) - c(sqrt(t) - sqrt(T))]}

parameters: A, b, T, c
variable: t (time)
resp: y


I tried:
time = 1:48
resp = rnorm(48, 200, 10)

dados = data.frame(resp, time)
attach(dados)

f = function(x, A, b, T, c)
  A*(1-exp(-b*(x-T) - c*(sqrt(x) - sqrt(T))))

(mod1 = nls(resp~f(time, A, b, c, T), data=dados,
           start=c(A=500, b=152, c=100, T=100)))

but isn't work. The error is:
+            start=c(A=10, b=152, c=10, T=10)))
Erro em numericDeriv(form[[3L]], names(ind), env) :
  Obtido valor faltante ou infinito quando avaliando o 
modelo

Somebody knows some package?

Thanks,

--------------------------------------
Silvano Cesar da Costa
Departamento de Estat?stica
Universidade Estadual de Londrina
Fone: 3371-4346
#
Given your starting values, there is nothing to optimize:
c*(sqrt(x) - sqrt(T))))
[1] -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf
-Inf -Inf
[16] -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf
-Inf -Inf
[31] -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf -Inf
-Inf -Inf
[46] -Inf -Inf -Inf

same with A = 500

So try to find a better model, or more sensible starting values.

Regards, Sven
On 05/04/2012 03:41 PM, Silvano wrote: