Problem from nonlinear mixed model

I got an error message when running code: saemix.fit1 <- saemix(saemix.model,, saemix.options)
Here is the error message:
Error in optim(par = phi1, fn = conditional.distribution_c, phii = phii, :
function cannot be evaluated at initial parameters

The entire program is:
library(saemix) <- saemixData( =, = "ID",
name.predictors = "Time",
name.response = "Concentration")

model1cpt <- function(psi,ID,x) {
D <- 320
t <-x[,1]
ka <-psi[ID,1]
V <-psi[ID,2]
ke <-psi[ID,3]
fpred <-Dka/(V(ka-ke))(exp(-ket)-exp(-ka*t))

saemix.model <- saemixModel(model = model1cpt,
psi0 = c(ka=1,V=20,ke=0.5))

saemix.options <- list(map=TRUE, fim=TRUE,, displayProgress=FALSE, seed=632545)
saemix.fit1 <- saemix(saemix.model,, saemix.options)

It is from - This website is for sale! - webpopix Resources and Information.
Part 3:

3.3 Fitting a NLME model to the theophylline data

data is available here: Theophylline - Data Sets
Appreciate very much if you can help solve the problem, thank you!

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.