Re: [R] R2OpenBUGS question with differential equations

2013-01-04 Thread Andras Farkas
  Andras From: Thomas Petzoldt To: r-help@r-project.org Sent: Thursday, January 3, 2013 12:51 PM Subject: Re: [R] R2OpenBUGS question with differential equations Dear Andreas, I don't understand your question, because I can't see any fundamental differen

Re: [R] R2OpenBUGS question with differential equations

2013-01-03 Thread Thomas Petzoldt
Dear Andreas, I don't understand your question, because I can't see any fundamental difference between differential equation models and any other R function. So why not rewriting your diffeq. model in the same way like the other example? And, please use package "deSolve" instead of "odesolve

[R] R2OpenBUGS question with differential equations

2013-01-03 Thread Andras Farkas
Dear All,   Currently I am running the following code:   library(stats4) library(odesolve) library(rgenoud) Input<-data.frame(SUB=c(1),time=c(0.5,3,10,15),lev=c(2.05,12.08,9.02,8)) XD<-500 IT<-3 diffeqfun<-function(time, y, parms) {   if(time<=IT)      dCpdt <- (XD/IT)/parms["Vol"] - (parms["Vm"