From 09104e678154881762199b8ba19d7683fac9155f Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Fri, 8 May 2020 01:16:03 +0200 Subject: Analytical SFO_SFO about as fast as deSolve compiled --- R/mkinfit.R | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'R/mkinfit.R') diff --git a/R/mkinfit.R b/R/mkinfit.R index 54dd75c2..1ddb6f36 100644 --- a/R/mkinfit.R +++ b/R/mkinfit.R @@ -459,8 +459,8 @@ mkinfit <- function(mkinmod, observed, # Prefer deSolve over eigen if a compiled model is present and use_compiled # is not set to FALSE solution_type = match.arg(solution_type) - if (solution_type == "analytical" && length(mkinmod$spec) > 1) - stop("Analytical solution not implemented for models with metabolites.") + if (solution_type == "analytical" && !is.function(mkinmod$deg_func)) + stop("Analytical solution not implemented for this model.") if (solution_type == "eigen" && !is.matrix(mkinmod$coefmat)) stop("Eigenvalue based solution not possible, coefficient matrix not present.") if (solution_type == "auto") { -- cgit v1.2.1