Closed EvanTarbell closed 5 years ago
nlmixr separates out a $PRED
type record and an $ODE
type record. The $PRED
record contains the parameters defined in the initial estimates block ini
. The $ODE
record contains the differential equations. If some parameters in the ini
block are in the $ODE
block then this error is thrown.
I think I have a solution to fix this, that is allow $ODE to have estimates from the ini
block directly listed, but I haven't implemented it yet.
I think I have fixed this in the github version.
If you want to try, I think you can update by the following:
.libPaths(.libPaths()[!grepl("Users",.libPaths()]) # I think this will take out the c:\Users\ libPath
.libPaths() # Check to make sure the Users path isn't there
devtools::install_github("nlmixrdevelopment/RxODE")
devtools::install_gitbhub("nlmixrdevelopment/nlmixr")
thanks for that. i actually just renamed my parameters and was able to solve this issue. I will try this new version soon. thanks
You may wish to wait for the next CRAN release. We are moving toward that very soon.
Thanks, that sounds like a plan. And thanks for all your help!!
I have a very complex, 64 compartment model that i am trying to fit. I tried getting the model into nlmixr format and tried checking it with nlmixr(model) and received the following error:
Reading through the code, it seems like the error is being thrown from this line in ui.R:
This seems to be checking a subset of the model code for the regular expression:
(?:d/dt\(|(?:\(0\)[[:space:]]*(?:=|~)))
and if it finds any matches, then it throws the error (if im understanding the code).It seems to imply that if the parameter assignments/declarations etc are with the ODE equations, then the error is thrown, but the parameters are listed first, followed by the ODE, followed by the concentration formulas, according to the nlmixr documentation. Im clearly formatting the model incorrectly but im not sure where or how. Any help is greatly appreciated. Thanks