aboutsummaryrefslogtreecommitdiff
path: root/R
diff options
context:
space:
mode:
authorjranke <jranke@edb9625f-4e0d-4859-8d74-9fd3b1da38cb>2013-03-04 11:39:23 +0000
committerjranke <jranke@edb9625f-4e0d-4859-8d74-9fd3b1da38cb>2013-03-04 11:39:23 +0000
commit63167b07c10b6b91f62cba3d7b5e705c07b338b9 (patch)
tree31005ceb8c825bdbc030e9d1cb3816df310d5e5c /R
parent3cdbc3b68a24455d6e7ec27353e3884d06efb442 (diff)
Introduce the possibility to place the legend with mkin using arguments lpos and inset
git-svn-id: svn+ssh://svn.r-forge.r-project.org/svnroot/kinfit/pkg/mkin@72 edb9625f-4e0d-4859-8d74-9fd3b1da38cb
Diffstat (limited to 'R')
-rw-r--r--R/plot.mkinfit.R5
1 files changed, 3 insertions, 2 deletions
diff --git a/R/plot.mkinfit.R b/R/plot.mkinfit.R
index 41b4cb33..5e2db394 100644
--- a/R/plot.mkinfit.R
+++ b/R/plot.mkinfit.R
@@ -28,7 +28,8 @@ plot.mkinfit <- function(x, fit = x,
col_obs = 1:length(fit$mkinmod$map),
pch_obs = col_obs,
lty_obs = rep(1, length(fit$mkinmod$map)),
- add = FALSE, legend = !add, ...)
+ add = FALSE, legend = !add,
+ lpos = "topright", inset = c(0.05, 0.05), ...)
{
solution_type = fit$solution_type
parms.all <- c(fit$bparms.optim, fit$bparms.fixed)
@@ -63,7 +64,7 @@ plot.mkinfit <- function(x, fit = x,
}
matlines(out$time, out[-1], col = col_obs, lty = lty_obs)
if (legend == TRUE) {
- legend("topright", inset=c(0.05, 0.05), legend=names(fit$mkinmod$map),
+ legend(lpos, inset= inset, legend=names(fit$mkinmod$map),
col=col_obs, pch=pch_obs, lty=lty_obs)
}
}

Contact - Imprint