diff options
author | Johannes Ranke <jranke@uni-bremen.de> | 2014-08-29 12:33:26 +0200 |
---|---|---|
committer | Johannes Ranke <jranke@uni-bremen.de> | 2014-08-29 12:33:26 +0200 |
commit | 2dc4f2f87048c28252992fe70055e0d7652a61ef (patch) | |
tree | c4221b528665b50932d30cdc231d90a2bb813bcc | |
parent | f30472ecd2afea6bd2153b8ad2bb2f663f3a2742 (diff) |
Avoid an unnecessary warning
-rw-r--r-- | NEWS.md | 8 | ||||
-rw-r--r-- | R/plot.mkinfit.R | 2 |
2 files changed, 5 insertions, 5 deletions
@@ -12,10 +12,10 @@ - `mkinfit()`: The initial value (state.ini) for the parent compound was not set when the parent was not the (only) variable with the highest value in the observed data. -- `mkinerrmin()`: When checking for degrees of freedom for metabolites, check - if their time zero value is fixed instead of checking if the observed value - is zero. This ensures correct calculation of degrees of freedom also in cases - where the metabolite residue at time zero is greater zero. +- `mkinerrmin()`: When checking for degrees of freedom for metabolites, check if their time zero value is fixed instead of checking if the observed value is zero. This ensures correct calculation of degrees of freedom also in cases where the metabolite residue at time zero is greater zero. + +- `plot.mkinfit()`: Avoid a warning message about only using the first component of ylim that occurred when ylim was specified explicitly + ## MINOR CHANGES diff --git a/R/plot.mkinfit.R b/R/plot.mkinfit.R index 4132d96c..31746fb8 100644 --- a/R/plot.mkinfit.R +++ b/R/plot.mkinfit.R @@ -31,7 +31,7 @@ plot.mkinfit <- function(x, fit = x, { if (add && show_residuals) stop("If adding to an existing plot we can not show residuals") - if (ylim == "default") { + if (ylim[[1]] == "default") { ylim = c(0, max(subset(fit$data, variable %in% obs_vars)$observed, na.rm = TRUE)) } |