diff options
author | Johannes Ranke <jranke@uni-bremen.de> | 2020-10-24 02:18:59 +0200 |
---|---|---|
committer | Johannes Ranke <jranke@uni-bremen.de> | 2020-10-24 02:18:59 +0200 |
commit | 60270e2849ebd48eaf57b83eb1aa9fbe53281f8b (patch) | |
tree | 644904ea42e6d35d6e43bb88733619b25347fcbb /R/plot.nlme.mmkin.R | |
parent | 6ad4e443b662e8c61b1b350d3e639e821a8ff764 (diff) |
Fix a bug for nlme with parent only, improve examples
Diffstat (limited to 'R/plot.nlme.mmkin.R')
-rw-r--r-- | R/plot.nlme.mmkin.R | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/R/plot.nlme.mmkin.R b/R/plot.nlme.mmkin.R index 2356070e..223aba68 100644 --- a/R/plot.nlme.mmkin.R +++ b/R/plot.nlme.mmkin.R @@ -99,7 +99,7 @@ plot.nlme.mmkin <- function(x, i = 1:ncol(x$mmkin_orig), transform_fractions = fit_1$transform_fractions) odeini <- degparms_all[ds_i, odeini_names] - names(odeini) <- gsub("_0", "", names(odeini)) + names(odeini) <- gsub("_0", "", odeini_names) out <- mkinpredict(x$mkinmod, odeparms, odeini, outtimes, solution_type = solution_type, @@ -116,7 +116,7 @@ plot.nlme.mmkin <- function(x, i = 1:ncol(x$mmkin_orig), transform_fractions = fit_1$transform_fractions) odeini_pop <- degparms_all_pop[odeini_names] - names(odeini_pop) <- gsub("_0", "", names(odeini_pop)) + names(odeini_pop) <- gsub("_0", "", odeini_names) pred_pop <- as.data.frame( mkinpredict(x$mkinmod, odeparms_pop, odeini_pop, @@ -171,7 +171,6 @@ plot.nlme.mmkin <- function(x, i = 1:ncol(x$mmkin_orig), maxabs = max(abs(observed_row$residual), na.rm = TRUE) } - if (identical(resplot, "time")) { plot(0, type = "n", xlim = xlim, xlab = "Time", ylim = c(-1.2 * maxabs, 1.2 * maxabs), |