diff options
author | jranke <jranke@edb9625f-4e0d-4859-8d74-9fd3b1da38cb> | 2012-04-23 23:08:19 +0000 |
---|---|---|
committer | jranke <jranke@edb9625f-4e0d-4859-8d74-9fd3b1da38cb> | 2012-04-23 23:08:19 +0000 |
commit | ea197b16fe5c582dd2a72e81d25c1ebbd5d527b3 (patch) | |
tree | 4bf946247020b9b29d8b06d3487af575d5bf4060 /R/mkinfit.R | |
parent | e3162e617bc268d9de92640311e2fbe650aa636a (diff) |
- Fixed a couple of things
- Now the eigenvalue based solutions are nicely consistent with the deSolve solutions, if enough
output times are specified (100, sometimes more are needed, see test.R)
- Workaround for invilr not to produce NaN values so often
- Still a lot to do (see TODO)
git-svn-id: svn+ssh://svn.r-forge.r-project.org/svnroot/kinfit/pkg/mkin@30 edb9625f-4e0d-4859-8d74-9fd3b1da38cb
Diffstat (limited to 'R/mkinfit.R')
-rw-r--r-- | R/mkinfit.R | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/R/mkinfit.R b/R/mkinfit.R index 37eee33..cf58a7d 100644 --- a/R/mkinfit.R +++ b/R/mkinfit.R @@ -111,6 +111,9 @@ mkinfit <- function(mkinmod, observed, {
assign("calls", calls+1, inherits=TRUE) # Increase the model solution counter
+ # Trace parameter values if quiet is off
+ if(!quiet) cat(P, "\n")
+
# Time points at which observed data are available
# Make sure we include time 0, so initial values for state variables are for time 0
outtimes = sort(unique(c(observed$time,
@@ -305,7 +308,8 @@ mkinfit <- function(mkinmod, observed, data$variable <- ordered(data$variable, levels = obs_vars)
fit$data <- data[order(data$variable, data$time), ]
fit$atol <- atol
- fit$parms.all <- parms.all
+ fit$parms.all <- parms.all # Return all backtransformed parameters for summary
+ fit$odeparms.final <- parms.all[mkinmod$parms] # Return ode parameters for further fitting
class(fit) <- c("mkinfit", "modFit")
return(fit)
|