From ea197b16fe5c582dd2a72e81d25c1ebbd5d527b3 Mon Sep 17 00:00:00 2001 From: jranke Date: Mon, 23 Apr 2012 23:08:19 +0000 Subject: - 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 --- R/mkinmod.R | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'R/mkinmod.R') diff --git a/R/mkinmod.R b/R/mkinmod.R index 54b3b5f4..41dbefa8 100644 --- a/R/mkinmod.R +++ b/R/mkinmod.R @@ -92,7 +92,7 @@ mkinmod <- function(..., use_of_ff = "min") parms <- c(parms, k_compound_sink) decline_term <- paste(k_compound_sink, "*", box_1) } else { # otherwise no decline term needed here - decline_term = "" + decline_term = "0" } } else { k_compound <- paste("k", box_1, sep="_") @@ -128,6 +128,10 @@ mkinmod <- function(..., use_of_ff = "min") reversible_binding_term_2 <- paste("+", k_free_bound, "*", box_1, "-", k_bound_free, "*", box_2) } else { # Use formation fractions also for the free compartment + stop("The maximum use of formation fractions is not supported for SFORB models") + # The problems were: Calculation of dissipation times did not work in this case + # and the coefficient matrix is not generated correctly by the code present + # in this file in this case f_free_bound <- paste("f", varname, "free", "bound", sep="_") k_bound_free <- paste("k", varname, "bound", "free", sep="_") parms <- c(parms, f_free_bound, k_bound_free) -- cgit v1.2.1