Hello list:

I'm attempting to fit some population growth models to venezuelan census data:

"time"    "pob"
1873    1732411
1881    2005139
1891    2221572
1920    2479525
1926    2814131
1936    3364347
1941    3850771
1950    5034838
1961    7523999
1971    10721522
1981    14516735
1990    18105265
2001    23232553
2011    27150095

For example, the code for the generalized logistic growth model (as given in Petzoldt's "Konstruktion ökologischer Mo delle mit der Open Source Software R", page 55) is thus:

#Modelos de crecimiento para la poblacion venezolana
#Primero, se lee la data de censo
censo <- read.table("censos.csv",header=TRUE)
library("simecol")
library("FME")
#Mdelo de crecimiento logistico generalizado
censo7 <- new("odeModel",
        main=function(time,init,parms, ...) {
            x <- init
            p <- parms
            dpob <- x["pob"]^p["alfa"]*p["c_anual"]*(1-(x["pob"]/p["K"])^p["beta"])^p["gamma"]
            list(dpob)},
        init=c(pob=1732411),
        parms=c(c_anual=0.02014121,K=100000000,alfa=1,beta=1,gamma=1),
        times=seq(from=1873,to=2011,by=1),
        solver="rk")
#fitOdeModel
resultado <- fitOdeModel(censo7,obstime=censo$time,
                         yobs=censo[2],fn=ssqOdeModel,
                         method = "PORT", lower = c(c_anual=0,K=0,alfa=0,beta=0,gamma=0),
                         scale=c(1/0.1,1/100000000,1/0.1,1/0.1) )
resultado
#FME
parms(censo7) <- c(c_anual=0.0000444,K=27390000,alfa=1.4,beta=1.6,gamma=0.2982)
fCosto <- function(p) {
    parms(censo7) <- p
    out <- out(sim(censo7))
    cost <- modCost(out, censo, weight="std")
    cost
}
ajuste <- modFit(f = fCosto, p = parms(censo7))
summary(ajuste)
#Fin

So my questions are as follows:

1) Other attempts to use fitOdeModels with a different solver other than "rk" ("lsoda" for example) fail.  Why is this?
2) There was no way to get FME's modFit to work.  Why is it giving me an error indicating that I need at least 2 non NA values to interpolate with approx? This error also resulted with fitOdeModel on other models with less "fortunate" guesses of initial parameter values. 

3}) An earlier attempt to use the Blumberg model, which is essentially a special case of the generalized logistic growth model minus one parameter was succesfull with bot modFit and fitOdeModel.  I tried feeding the resulting parameter values of the Blumberg model to the generalized model, but no success.  An attempt to use the "pseudo" method in modFit first and the retrofeed the parameter values back into modFit for further searching, as suggested in the FME vignette was not successful either.

What I am doing wrong in this?

Thanks in advance,

jose romero
	[[alternative HTML version deleted]]

