diff options
author | = <=> | 2013-12-04 10:25:14 +0100 |
---|---|---|
committer | = <=> | 2013-12-04 10:25:14 +0100 |
commit | 8b94131388071980e62c17190eb4229e89975a0c (patch) | |
tree | 48f90fae958d466076f9f3b0aa8ec733c9c7bbee /R/mkinfit.R | |
parent | f7be9d1c545b6385f53603d2861e0a16e3044165 (diff) |
Make it possible to use different ode solvers
Diffstat (limited to 'R/mkinfit.R')
-rw-r--r-- | R/mkinfit.R | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/R/mkinfit.R b/R/mkinfit.R index 3e47479f..749d7485 100644 --- a/R/mkinfit.R +++ b/R/mkinfit.R @@ -1,5 +1,3 @@ -# $Id$
-
# Copyright (C) 2010-2013 Johannes Ranke
# Contact: jranke@uni-bremen.de
# The summary function is an adapted and extended version of summary.modFit
@@ -28,6 +26,7 @@ mkinfit <- function(mkinmod, observed, fixed_parms = NULL,
fixed_initials = names(mkinmod$diffs)[-1],
solution_type = "auto",
+ method.ode = "lsoda",
method.modFit = "Marq",
control.modFit = list(),
plot = FALSE, quiet = FALSE,
@@ -161,6 +160,7 @@ mkinfit <- function(mkinmod, observed, # Solve the system with current transformed parameter values
out <- mkinpredict(mkinmod, parms, odeini, outtimes,
solution_type = solution_type,
+ method.ode = method.ode,
atol = atol, rtol = rtol, ...)
assign("out_predicted", out, inherits=TRUE)
@@ -177,7 +177,9 @@ mkinfit <- function(mkinmod, observed, outtimes_plot = seq(min(observed$time), max(observed$time), length.out=100)
out_plot <- mkinpredict(mkinmod, parms, odeini, outtimes_plot,
- solution_type = solution_type, atol = atol, rtol = rtol, ...)
+ solution_type = solution_type,
+ method.ode = method.ode,
+ atol = atol, rtol = rtol, ...)
plot(0, type="n",
xlim = range(observed$time), ylim = range(observed$value, na.rm=TRUE),
|