aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Ranke <jranke@uni-bremen.de>2016-11-17 22:58:28 +0100
committerJohannes Ranke <jranke@uni-bremen.de>2016-11-17 22:58:28 +0100
commit98d684becd9495d370e1bcc8f9c7ca758caa4dd8 (patch)
tree94c5e18f755d1c3328fad3fe517fe28b45c2df2f
parent3f6ce570824616f5be0d6289ed65910d455dd266 (diff)
Static documentation rebuilt by pkgdown::build_site()
-rw-r--r--docs/articles/FOCUS_D.R20
-rw-r--r--docs/articles/FOCUS_D.html10
-rw-r--r--docs/articles/FOCUS_D_cache/html/__packages4
-rw-r--r--docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.RDatabin0 -> 3175 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.rdb (renamed from docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.rdb)0
-rw-r--r--docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.rdx (renamed from docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.rdx)bin113 -> 113 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.RDatabin0 -> 2735 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdbbin0 -> 15588 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdxbin0 -> 161 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.RDatabin0 -> 2927 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdbbin0 -> 1776 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdxbin0 -> 147 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.RData (renamed from docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.RData)bin2769 -> 2769 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.rdb (renamed from docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.rdb)0
-rw-r--r--docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.rdx (renamed from docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.rdx)bin113 -> 113 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.RData (renamed from docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.RData)bin2781 -> 2799 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdb0
-rw-r--r--docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdxbin0 -> 113 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.RDatabin0 -> 4629 bytes
-rw-r--r--docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdb0
-rw-r--r--docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdxbin0 -> 113 bytes
-rw-r--r--docs/articles/FOCUS_D_files/figure-html/plot-1.pngbin74304 -> 95834 bytes
-rw-r--r--docs/articles/FOCUS_D_files/figure-html/plot_2-1.pngbin13789 -> 14059 bytes
-rw-r--r--docs/articles/FOCUS_L.R49
-rw-r--r--docs/articles/FOCUS_L.html74
-rw-r--r--docs/articles/FOCUS_Z.R32
-rw-r--r--docs/articles/FOCUS_Z.Rnw66
-rw-r--r--docs/articles/FOCUS_Z.pdfbin239558 -> 239558 bytes
-rw-r--r--docs/articles/compiled_models.R10
-rw-r--r--docs/articles/compiled_models.html42
-rw-r--r--docs/articles/compiled_models_files/figure-html/benchmark_FOMC_SFO-1.pngbin10652 -> 9514 bytes
-rw-r--r--docs/articles/compiled_models_files/figure-html/benchmark_SFO_SFO-1.pngbin11994 -> 11028 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_1-1.pdfbin7496 -> 7496 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_10-1.pdfbin11048 -> 11048 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_11-1.pdfbin11072 -> 11072 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_11a-1.pdfbin10940 -> 10940 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_11b-1.pdfbin5023 -> 5023 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_2-1.pdfbin7481 -> 7481 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_3-1.pdfbin7482 -> 7482 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_5-1.pdfbin9099 -> 9099 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_6-1.pdfbin10771 -> 10771 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_7-1.pdfbin10754 -> 10754 bytes
-rw-r--r--docs/articles/figure/FOCUS_2006_Z_fits_9-1.pdfbin9392 -> 9392 bytes
-rw-r--r--docs/articles/mkin.R24
-rw-r--r--docs/articles/mkin.html28
-rw-r--r--docs/articles/mkin_cache/html/__packages13
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.RDatabin0 -> 3376 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdbbin0 -> 105223 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdxbin0 -> 236 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.RDatabin3274 -> 0 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdbbin20269 -> 0 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdxbin226 -> 0 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.RDatabin3144 -> 0 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdbbin105089 -> 0 bytes
-rw-r--r--docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdxbin235 -> 0 bytes
-rw-r--r--docs/articles/mkin_files/figure-html/unnamed-chunk-2-1.pngbin45379 -> 112161 bytes
-rw-r--r--docs/articles/references.bib6
-rw-r--r--docs/index.html8
-rw-r--r--docs/reference/Extract.mmkin.html26
-rw-r--r--docs/reference/add_err.html4
-rw-r--r--docs/reference/endpoints.html4
-rw-r--r--docs/reference/ilr.html2
-rw-r--r--docs/reference/mccall81_245T.html12
-rw-r--r--docs/reference/mkin_long_to_wide.html8
-rw-r--r--docs/reference/mkin_wide_to_long.html4
-rw-r--r--docs/reference/mkinfit.html50
-rw-r--r--docs/reference/mkinpredict.html12
-rw-r--r--docs/reference/mkinsub.html8
-rw-r--r--docs/reference/mmkin.html4
-rw-r--r--docs/reference/plot.mkinfit.html14
-rw-r--r--docs/reference/plot.mmkin.html4
-rw-r--r--docs/reference/summary.mkinfit.html8
-rw-r--r--docs/reference/transform_odeparms.html26
73 files changed, 322 insertions, 250 deletions
diff --git a/docs/articles/FOCUS_D.R b/docs/articles/FOCUS_D.R
index c3881e80..9eaf41f7 100644
--- a/docs/articles/FOCUS_D.R
+++ b/docs/articles/FOCUS_D.R
@@ -2,23 +2,3 @@
library(knitr)
opts_chunk$set(tidy = FALSE, cache = TRUE)
-## ----data----------------------------------------------------------------
-library("mkin")
-print(FOCUS_2006_D)
-
-## ----model---------------------------------------------------------------
-SFO_SFO <- mkinmod(parent = mkinsub("SFO", "m1"), m1 = mkinsub("SFO"))
-print(SFO_SFO$diffs)
-
-## ----fit-----------------------------------------------------------------
-fit <- mkinfit(SFO_SFO, FOCUS_2006_D, quiet = TRUE)
-
-## ----plot, fig.height = 5------------------------------------------------
-plot(fit, show_residuals = TRUE)
-
-## ----plot_2, fig.height = 4----------------------------------------------
-mkinparplot(fit)
-
-## ------------------------------------------------------------------------
-summary(fit)
-
diff --git a/docs/articles/FOCUS_D.html b/docs/articles/FOCUS_D.html
index 1c4edbd0..776e1093 100644
--- a/docs/articles/FOCUS_D.html
+++ b/docs/articles/FOCUS_D.html
@@ -41,7 +41,7 @@
<h1>Example evaluation of FOCUS Example Dataset D</h1>
<h4 class="author">Johannes Ranke</h4>
- <h4 class="date">2016-11-04</h4>
+ <h4 class="date">2016-11-17</h4>
</div>
@@ -106,12 +106,12 @@
## "d_m1 = + k_parent_m1 * parent - k_m1_sink * m1"</code></pre>
<p>We do the fitting without progress report (<code>quiet = TRUE</code>).</p>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r">fit &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(SFO_SFO, FOCUS_2006_D, <span class="dt">quiet =</span> <span class="ot">TRUE</span>)</code></pre></div>
-<p>A plot of the fit including a residual plot for both observed variables is obtained using the <code>plot</code> method for <code>mkinfit</code> objects.</p>
-<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">plot</span>(fit, <span class="dt">show_residuals =</span> <span class="ot">TRUE</span>)</code></pre></div>
-<p><img src="FOCUS_D_files/figure-html/plot-1.png" width="672"></p>
+<p>A plot of the fit including a residual plot for both observed variables is obtained using the <code>plot_sep</code> method for <code>mkinfit</code> objects, which shows separate graphs for all compounds and their residuals.</p>
+<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw"><a href="../reference/plot.mkinfit.html">plot_sep</a></span>(fit, <span class="dt">lpos =</span> <span class="kw">c</span>(<span class="st">"topright"</span>, <span class="st">"bottomright"</span>))</code></pre></div>
+<p><img src="FOCUS_D_files/figure-html/plot-1.png" width="768"></p>
<p>Confidence intervals for the parameter estimates are obtained using the <code>mkinparplot</code> function.</p>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw"><a href="../reference/mkinparplot.html">mkinparplot</a></span>(fit)</code></pre></div>
-<p><img src="FOCUS_D_files/figure-html/plot_2-1.png" width="672"></p>
+<p><img src="FOCUS_D_files/figure-html/plot_2-1.png" width="768"></p>
<p>A comprehensive report of the results is obtained using the <code>summary</code> method for <code>mkinfit</code> objects.</p>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">summary</span>(fit)</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
diff --git a/docs/articles/FOCUS_D_cache/html/__packages b/docs/articles/FOCUS_D_cache/html/__packages
index 8042c1f3..f8bbf624 100644
--- a/docs/articles/FOCUS_D_cache/html/__packages
+++ b/docs/articles/FOCUS_D_cache/html/__packages
@@ -1,8 +1,12 @@
base
+colorout
+setwidth
+nvimcom
minpack.lm
rootSolve
inline
mkin
+rmarkdown
knitr
microbenchmark
ggplot2
diff --git a/docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.RData b/docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.RData
new file mode 100644
index 00000000..f338ef34
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.RData
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.rdb b/docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.rdb
index e69de29b..e69de29b 100644
--- a/docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.rdb
+++ b/docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.rdb
diff --git a/docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.rdx b/docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.rdx
index 20f10d9f..20f10d9f 100644
--- a/docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.rdx
+++ b/docs/articles/FOCUS_D_cache/html/data_7c3240ac153a7639ee517a9110a0f103.rdx
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.RData b/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.RData
new file mode 100644
index 00000000..8c2535e9
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.RData
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdb b/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdb
new file mode 100644
index 00000000..91f5819c
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdb
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdx b/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdx
new file mode 100644
index 00000000..e56a127f
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/fit_33941ca5d01df032930f2f38dc298a59.rdx
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.RData b/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.RData
new file mode 100644
index 00000000..4ebde526
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.RData
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdb b/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdb
new file mode 100644
index 00000000..f7dd80c1
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdb
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdx b/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdx
new file mode 100644
index 00000000..583dc40b
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/model_7de92bef541220dbe2d2832243e35870.rdx
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.RData b/docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.RData
index 8637b712..b1195f70 100644
--- a/docs/articles/FOCUS_D_cache/html/plot_2_3aa531f4c45b3e89e3259e0bb1cf7cf7.RData
+++ b/docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.RData
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.rdb b/docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.rdb
index e69de29b..e69de29b 100644
--- a/docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.rdb
+++ b/docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.rdb
diff --git a/docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.rdx b/docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.rdx
index 20f10d9f..20f10d9f 100644
--- a/docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.rdx
+++ b/docs/articles/FOCUS_D_cache/html/plot_2_2d898a5ad88ebcba8bdab623bfd497de.rdx
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.RData b/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.RData
index ac6cd420..e559f15f 100644
--- a/docs/articles/FOCUS_D_cache/html/plot_7873ad9c0e1495350681617620f6522d.RData
+++ b/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.RData
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdb b/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdb
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdb
diff --git a/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdx b/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdx
new file mode 100644
index 00000000..20f10d9f
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/plot_a02b9c8bb9ae9921707cd87235ec2008.rdx
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.RData b/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.RData
new file mode 100644
index 00000000..03aae95c
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.RData
Binary files differ
diff --git a/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdb b/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdb
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdb
diff --git a/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdx b/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdx
new file mode 100644
index 00000000..20f10d9f
--- /dev/null
+++ b/docs/articles/FOCUS_D_cache/html/unnamed-chunk-2_2c30ef6f2fb33a606bda3c2882a070ab.rdx
Binary files differ
diff --git a/docs/articles/FOCUS_D_files/figure-html/plot-1.png b/docs/articles/FOCUS_D_files/figure-html/plot-1.png
index c0b0c2db..fc237898 100644
--- a/docs/articles/FOCUS_D_files/figure-html/plot-1.png
+++ b/docs/articles/FOCUS_D_files/figure-html/plot-1.png
Binary files differ
diff --git a/docs/articles/FOCUS_D_files/figure-html/plot_2-1.png b/docs/articles/FOCUS_D_files/figure-html/plot_2-1.png
index 6700e527..b0a7c26b 100644
--- a/docs/articles/FOCUS_D_files/figure-html/plot_2-1.png
+++ b/docs/articles/FOCUS_D_files/figure-html/plot_2-1.png
Binary files differ
diff --git a/docs/articles/FOCUS_L.R b/docs/articles/FOCUS_L.R
index 858d483e..063e3d57 100644
--- a/docs/articles/FOCUS_L.R
+++ b/docs/articles/FOCUS_L.R
@@ -1,3 +1,50 @@
+## ---- include = FALSE----------------------------------------------------
+library(knitr)
+opts_chunk$set(tidy = FALSE, cache = FALSE)
+
+## ------------------------------------------------------------------------
+library("mkin", quietly = TRUE)
+FOCUS_2006_L1 = data.frame(
+ t = rep(c(0, 1, 2, 3, 5, 7, 14, 21, 30), each = 2),
+ parent = c(88.3, 91.4, 85.6, 84.5, 78.9, 77.6,
+ 72.0, 71.9, 50.3, 59.4, 47.0, 45.1,
+ 27.7, 27.3, 10.0, 10.4, 2.9, 4.0))
+FOCUS_2006_L1_mkin <- mkin_wide_to_long(FOCUS_2006_L1)
+
+## ------------------------------------------------------------------------
+m.L1.SFO <- mkinfit("SFO", FOCUS_2006_L1_mkin, quiet = TRUE)
+summary(m.L1.SFO)
+
+## ----fig.width = 6, fig.height = 5---------------------------------------
+plot(m.L1.SFO, show_errmin = TRUE, main = "FOCUS L1 - SFO")
+
+## ----fig.width = 6, fig.height = 5---------------------------------------
+mkinresplot(m.L1.SFO, ylab = "Observed", xlab = "Time")
+
+## ----fig.width = 6, fig.height = 5---------------------------------------
+m.L1.FOMC <- mkinfit("FOMC", FOCUS_2006_L1_mkin, quiet=TRUE)
+plot(m.L1.FOMC, show_errmin = TRUE, main = "FOCUS L1 - FOMC")
+summary(m.L1.FOMC, data = FALSE)
+
+## ------------------------------------------------------------------------
+FOCUS_2006_L2 = data.frame(
+ t = rep(c(0, 1, 3, 7, 14, 28), each = 2),
+ parent = c(96.1, 91.8, 41.4, 38.7,
+ 19.3, 22.3, 4.6, 4.6,
+ 2.6, 1.2, 0.3, 0.6))
+FOCUS_2006_L2_mkin <- mkin_wide_to_long(FOCUS_2006_L2)
+
+## ----fig.width = 7, fig.height = 6---------------------------------------
+m.L2.SFO <- mkinfit("SFO", FOCUS_2006_L2_mkin, quiet=TRUE)
+plot(m.L2.SFO, show_residuals = TRUE, show_errmin = TRUE,
+ main = "FOCUS L2 - SFO")
+
+## ----fig.width = 7, fig.height = 6---------------------------------------
+m.L2.FOMC <- mkinfit("FOMC", FOCUS_2006_L2_mkin, quiet = TRUE)
+plot(m.L2.FOMC, show_residuals = TRUE,
+ main = "FOCUS L2 - FOMC")
+summary(m.L2.FOMC, data = FALSE)
+
## ----fig.width = 7, fig.height = 6---------------------------------------
m.L2.DFOP <- mkinfit("DFOP", FOCUS_2006_L2_mkin, quiet = TRUE)
plot(m.L2.DFOP, show_residuals = TRUE, show_errmin = TRUE,
@@ -29,7 +76,7 @@ FOCUS_2006_L4_mkin <- mkin_wide_to_long(FOCUS_2006_L4)
## ----fig.height = 6------------------------------------------------------
# Only use one core here, not to offend the CRAN checks
mm.L4 <- mmkin(c("SFO", "FOMC"), cores = 1,
- list("FOCUS L4" = FOCUS_2006_L4_mkin),
+ list("FOCUS L4" = FOCUS_2006_L4_mkin),
quiet = TRUE)
plot(mm.L4)
diff --git a/docs/articles/FOCUS_L.html b/docs/articles/FOCUS_L.html
index 4c3e5c9b..e7ec5308 100644
--- a/docs/articles/FOCUS_L.html
+++ b/docs/articles/FOCUS_L.html
@@ -41,7 +41,7 @@
<h1>Example evaluation of FOCUS Laboratory Data L1 to L3</h1>
<h4 class="author">Johannes Ranke</h4>
- <h4 class="date">2016-11-04</h4>
+ <h4 class="date">2016-11-17</h4>
</div>
@@ -53,7 +53,7 @@
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">library</span>(<span class="st">"mkin"</span>, <span class="dt">quietly =</span> <span class="ot">TRUE</span>)
FOCUS_2006_L1 =<span class="st"> </span><span class="kw">data.frame</span>(
<span class="dt">t =</span> <span class="kw">rep</span>(<span class="kw">c</span>(<span class="dv">0</span>, <span class="dv">1</span>, <span class="dv">2</span>, <span class="dv">3</span>, <span class="dv">5</span>, <span class="dv">7</span>, <span class="dv">14</span>, <span class="dv">21</span>, <span class="dv">30</span>), <span class="dt">each =</span> <span class="dv">2</span>),
- <span class="dt">parent =</span> <span class="kw">c</span>(<span class="fl">88.3</span>, <span class="fl">91.4</span>, <span class="fl">85.6</span>, <span class="fl">84.5</span>, <span class="fl">78.9</span>, <span class="fl">77.6</span>,
+ <span class="dt">parent =</span> <span class="kw">c</span>(<span class="fl">88.3</span>, <span class="fl">91.4</span>, <span class="fl">85.6</span>, <span class="fl">84.5</span>, <span class="fl">78.9</span>, <span class="fl">77.6</span>,
<span class="fl">72.0</span>, <span class="fl">71.9</span>, <span class="fl">50.3</span>, <span class="fl">59.4</span>, <span class="fl">47.0</span>, <span class="fl">45.1</span>,
<span class="fl">27.7</span>, <span class="fl">27.3</span>, <span class="fl">10.0</span>, <span class="fl">10.4</span>, <span class="fl">2.9</span>, <span class="fl">4.0</span>))
FOCUS_2006_L1_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mkin_wide_to_long.html">mkin_wide_to_long</a></span>(FOCUS_2006_L1)</code></pre></div>
@@ -63,15 +63,15 @@ FOCUS_2006_L1_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
<span class="kw">summary</span>(m.L1.SFO)</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
## R version: 3.3.2
-## Date of fit: Fri Nov 4 17:13:56 2016
-## Date of summary: Fri Nov 4 17:13:56 2016
+## Date of fit: Thu Nov 17 22:58:18 2016
+## Date of summary: Thu Nov 17 22:58:18 2016
##
## Equations:
-## d_parent = - k_parent_sink * parent
+## d_parent/dt = - k_parent_sink * parent
##
## Model predictions using solution type analytical
##
-## Fitted with method Port using 37 model solutions performed in 0.089 s
+## Fitted with method Port using 37 model solutions performed in 0.103 s
##
## Weighting: none
##
@@ -156,8 +156,8 @@ FOCUS_2006_L1_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">summary</span>(m.L1.FOMC, <span class="dt">data =</span> <span class="ot">FALSE</span>)</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
## R version: 3.3.2
-## Date of fit: Fri Nov 4 17:13:57 2016
-## Date of summary: Fri Nov 4 17:13:57 2016
+## Date of fit: Thu Nov 17 22:58:19 2016
+## Date of summary: Thu Nov 17 22:58:19 2016
##
##
## Warning: Optimisation by method Port did not converge.
@@ -165,11 +165,11 @@ FOCUS_2006_L1_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
##
##
## Equations:
-## d_parent = - (alpha/beta) * 1/((time/beta) + 1) * parent
+## d_parent/dt = - (alpha/beta) * 1/((time/beta) + 1) * parent
##
## Model predictions using solution type analytical
##
-## Fitted with method Port using 188 model solutions performed in 0.444 s
+## Fitted with method Port using 188 model solutions performed in 0.462 s
##
## Weighting: none
##
@@ -221,7 +221,7 @@ FOCUS_2006_L1_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
## parent 7.25 24.08 7.25</code></pre>
<p>We get a warning that the default optimisation algorithm <code>Port</code> did not converge, which is an indication that the model is overparameterised, <em>i.e.</em> contains too many parameters that are ill-defined as a consequence.</p>
<p>And in fact, due to the higher number of parameters, and the lower number of degrees of freedom of the fit, the <span class="math inline">\(\chi^2\)</span> error level is actually higher for the FOMC model (3.6%) than for the SFO model (3.4%). Additionally, the parameters <code>log_alpha</code> and <code>log_beta</code> internally fitted in the model have excessive confidence intervals, that span more than 25 orders of magnitude (!) when backtransformed to the scale of <code>alpha</code> and <code>beta</code>. Also, the t-test for significant difference from zero does not indicate such a significant difference, with p-values greater than 0.1, and finally, the parameter correlation of <code>log_alpha</code> and <code>log_beta</code> is 1.000, clearly indicating that the model is overparameterised.</p>
-<p>The <span class="math inline">\(\chi^2\)</span> error levels reported in Appendix 3 and Appendix 7 to the FOCUS kinetics report are rounded to integer percentages and partly deviate by one percentage point from the results calculated by mkin. The reason for this is not known. However, mkin gives the same <span class="math inline">\(\chi^2\)</span> error levels as the kinfit package and the calculation routines of the kinfit package have been extensively compared to the results obtained by the KinGUI software, as documented in the kinfit package vignette. KinGUI was the first widely used standard package in this field. Also, the calculation of <span class="math inline">\(\chi^2\)</span> error levels was compared with KinGUII, CAKE and DegKin manager in a project sponsored by the German Umweltbundesamt <span class="citation">(Ranke, n.d.)</span>.</p>
+<p>The <span class="math inline">\(\chi^2\)</span> error levels reported in Appendix 3 and Appendix 7 to the FOCUS kinetics report are rounded to integer percentages and partly deviate by one percentage point from the results calculated by mkin. The reason for this is not known. However, mkin gives the same <span class="math inline">\(\chi^2\)</span> error levels as the kinfit package and the calculation routines of the kinfit package have been extensively compared to the results obtained by the KinGUI software, as documented in the kinfit package vignette. KinGUI was the first widely used standard package in this field. Also, the calculation of <span class="math inline">\(\chi^2\)</span> error levels was compared with KinGUII, CAKE and DegKin manager in a project sponsored by the German Umweltbundesamt <span class="citation">(Ranke 2014)</span>.</p>
</div>
<div id="laboratory-data-l2" class="section level1">
<h1 class="hasAnchor"><html><body><a href="#laboratory-data-l2" class="anchor"> </a></body></html>Laboratory Data L2</h1>
@@ -236,7 +236,7 @@ FOCUS_2006_L2_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
<h2 class="hasAnchor"><html><body><a href="#sfo-fit-for-l2" class="anchor"> </a></body></html>SFO fit for L2</h2>
<p>Again, the SFO model is fitted and the result is plotted. The residual plot can be obtained simply by adding the argument <code>show_residuals</code> to the plot command.</p>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r">m.L2.SFO &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(<span class="st">"SFO"</span>, FOCUS_2006_L2_mkin, <span class="dt">quiet=</span><span class="ot">TRUE</span>)
-<span class="kw">plot</span>(m.L2.SFO, <span class="dt">show_residuals =</span> <span class="ot">TRUE</span>, <span class="dt">show_errmin =</span> <span class="ot">TRUE</span>,
+<span class="kw">plot</span>(m.L2.SFO, <span class="dt">show_residuals =</span> <span class="ot">TRUE</span>, <span class="dt">show_errmin =</span> <span class="ot">TRUE</span>,
<span class="dt">main =</span> <span class="st">"FOCUS L2 - SFO"</span>)</code></pre></div>
<p><img src="FOCUS_L_files/figure-html/unnamed-chunk-8-1.png" width="672"></p>
<p>The <span class="math inline">\(\chi^2\)</span> error level of 14% suggests that the model does not fit very well. This is also obvious from the plots of the fit, in which we have included the residual plot.</p>
@@ -253,15 +253,15 @@ FOCUS_2006_L2_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">summary</span>(m.L2.FOMC, <span class="dt">data =</span> <span class="ot">FALSE</span>)</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
## R version: 3.3.2
-## Date of fit: Fri Nov 4 17:13:58 2016
-## Date of summary: Fri Nov 4 17:13:58 2016
+## Date of fit: Thu Nov 17 22:58:20 2016
+## Date of summary: Thu Nov 17 22:58:20 2016
##
## Equations:
-## d_parent = - (alpha/beta) * 1/((time/beta) + 1) * parent
+## d_parent/dt = - (alpha/beta) * 1/((time/beta) + 1) * parent
##
## Model predictions using solution type analytical
##
-## Fitted with method Port using 81 model solutions performed in 0.194 s
+## Fitted with method Port using 81 model solutions performed in 0.195 s
##
## Weighting: none
##
@@ -323,17 +323,17 @@ FOCUS_2006_L2_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">summary</span>(m.L2.DFOP, <span class="dt">data =</span> <span class="ot">FALSE</span>)</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
## R version: 3.3.2
-## Date of fit: Fri Nov 4 17:13:59 2016
-## Date of summary: Fri Nov 4 17:13:59 2016
+## Date of fit: Thu Nov 17 22:58:21 2016
+## Date of summary: Thu Nov 17 22:58:21 2016
##
## Equations:
-## d_parent = - ((k1 * g * exp(-k1 * time) + k2 * (1 - g) * exp(-k2 *
-## time)) / (g * exp(-k1 * time) + (1 - g) * exp(-k2 *
-## time))) * parent
+## d_parent/dt = - ((k1 * g * exp(-k1 * time) + k2 * (1 - g) *
+## exp(-k2 * time)) / (g * exp(-k1 * time) + (1 - g) *
+## exp(-k2 * time))) * parent
##
## Model predictions using solution type analytical
##
-## Fitted with method Port using 336 model solutions performed in 0.82 s
+## Fitted with method Port using 336 model solutions performed in 0.882 s
##
## Weighting: none
##
@@ -412,17 +412,17 @@ mm.L3 &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mmkin
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">summary</span>(mm.L3[[<span class="st">"DFOP"</span>, <span class="dv">1</span>]])</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
## R version: 3.3.2
-## Date of fit: Fri Nov 4 17:14:00 2016
-## Date of summary: Fri Nov 4 17:14:00 2016
+## Date of fit: Thu Nov 17 22:58:22 2016
+## Date of summary: Thu Nov 17 22:58:22 2016
##
## Equations:
-## d_parent = - ((k1 * g * exp(-k1 * time) + k2 * (1 - g) * exp(-k2 *
-## time)) / (g * exp(-k1 * time) + (1 - g) * exp(-k2 *
-## time))) * parent
+## d_parent/dt = - ((k1 * g * exp(-k1 * time) + k2 * (1 - g) *
+## exp(-k2 * time)) / (g * exp(-k1 * time) + (1 - g) *
+## exp(-k2 * time))) * parent
##
## Model predictions using solution type analytical
##
-## Fitted with method Port using 137 model solutions performed in 0.336 s
+## Fitted with method Port using 137 model solutions performed in 0.338 s
##
## Weighting: none
##
@@ -504,7 +504,7 @@ FOCUS_2006_L4_mkin &lt;-<span class="st"> </span><span class="kw"><a href="../re
<p>Fits of the SFO and FOMC models, plots and summaries are produced below:</p>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="co"># Only use one core here, not to offend the CRAN checks</span>
mm.L4 &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mmkin.html">mmkin</a></span>(<span class="kw">c</span>(<span class="st">"SFO"</span>, <span class="st">"FOMC"</span>), <span class="dt">cores =</span> <span class="dv">1</span>,
- <span class="kw">list</span>(<span class="st">"FOCUS L4"</span> =<span class="st"> </span>FOCUS_2006_L4_mkin),
+ <span class="kw">list</span>(<span class="st">"FOCUS L4"</span> =<span class="st"> </span>FOCUS_2006_L4_mkin),
<span class="dt">quiet =</span> <span class="ot">TRUE</span>)
<span class="kw">plot</span>(mm.L4)</code></pre></div>
<p><img src="FOCUS_L_files/figure-html/unnamed-chunk-15-1.png" width="672"></p>
@@ -512,11 +512,11 @@ mm.L4 &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mmkin
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">summary</span>(mm.L4[[<span class="st">"SFO"</span>, <span class="dv">1</span>]], <span class="dt">data =</span> <span class="ot">FALSE</span>)</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
## R version: 3.3.2
-## Date of fit: Fri Nov 4 17:14:01 2016
-## Date of summary: Fri Nov 4 17:14:01 2016
+## Date of fit: Thu Nov 17 22:58:22 2016
+## Date of summary: Thu Nov 17 22:58:23 2016
##
## Equations:
-## d_parent = - k_parent_sink * parent
+## d_parent/dt = - k_parent_sink * parent
##
## Model predictions using solution type analytical
##
@@ -572,15 +572,15 @@ mm.L4 &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mmkin
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">summary</span>(mm.L4[[<span class="st">"FOMC"</span>, <span class="dv">1</span>]], <span class="dt">data =</span> <span class="ot">FALSE</span>)</code></pre></div>
<pre><code>## mkin version: 0.9.44.9000
## R version: 3.3.2
-## Date of fit: Fri Nov 4 17:14:01 2016
-## Date of summary: Fri Nov 4 17:14:01 2016
+## Date of fit: Thu Nov 17 22:58:23 2016
+## Date of summary: Thu Nov 17 22:58:23 2016
##
## Equations:
-## d_parent = - (alpha/beta) * 1/((time/beta) + 1) * parent
+## d_parent/dt = - (alpha/beta) * 1/((time/beta) + 1) * parent
##
## Model predictions using solution type analytical
##
-## Fitted with method Port using 66 model solutions performed in 0.162 s
+## Fitted with method Port using 66 model solutions performed in 0.151 s
##
## Weighting: none
##
@@ -635,7 +635,7 @@ mm.L4 &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mmkin
<h1 class="hasAnchor"><html><body><a href="#references" class="anchor"> </a></body></html>References</h1>
<div id="refs" class="references">
<div id="ref-ranke2014">
-<p>Ranke, Johannes. n.d. &ldquo;Pr&uuml;fung und Validierung von Modellierungssoftware als Alternative zu ModelMaker 4.0.&rdquo; Umweltbundesamt Projektnummer 27452.</p>
+<p>Ranke, Johannes. 2014. &ldquo;Pr&uuml;fung und Validierung von Modellierungssoftware als Alternative zu ModelMaker 4.0.&rdquo; Umweltbundesamt Projektnummer 27452.</p>
</div>
</div>
</div>
diff --git a/docs/articles/FOCUS_Z.R b/docs/articles/FOCUS_Z.R
index 5fc8f123..5c70b57e 100644
--- a/docs/articles/FOCUS_Z.R
+++ b/docs/articles/FOCUS_Z.R
@@ -1,3 +1,25 @@
+## ----include=FALSE--------------------------------------------------
+require(knitr)
+opts_chunk$set(engine='R', tidy = FALSE, cache = TRUE)
+options(width=70)
+
+## ----FOCUS_2006_Z_data, echo=TRUE, eval=TRUE------------------------
+require(mkin)
+LOD = 0.5
+FOCUS_2006_Z = data.frame(
+ t = c(0, 0.04, 0.125, 0.29, 0.54, 1, 2, 3, 4, 7, 10, 14, 21,
+ 42, 61, 96, 124),
+ Z0 = c(100, 81.7, 70.4, 51.1, 41.2, 6.6, 4.6, 3.9, 4.6, 4.3, 6.8,
+ 2.9, 3.5, 5.3, 4.4, 1.2, 0.7),
+ Z1 = c(0, 18.3, 29.6, 46.3, 55.1, 65.7, 39.1, 36, 15.3, 5.6, 1.1,
+ 1.6, 0.6, 0.5 * LOD, NA, NA, NA),
+ Z2 = c(0, NA, 0.5 * LOD, 2.6, 3.8, 15.3, 37.2, 31.7, 35.6, 14.5,
+ 0.8, 2.1, 1.9, 0.5 * LOD, NA, NA, NA),
+ Z3 = c(0, NA, NA, NA, NA, 0.5 * LOD, 9.2, 13.1, 22.3, 28.4, 32.5,
+ 25.2, 17.2, 4.8, 4.5, 2.8, 4.4))
+
+FOCUS_2006_Z_mkin <- mkin_wide_to_long(FOCUS_2006_Z)
+
## ----FOCUS_2006_Z_fits_1, echo=TRUE, fig.height=6-------------------
Z.2a <- mkinmod(Z0 = mkinsub("SFO", "Z1"),
Z1 = mkinsub("SFO"))
@@ -32,9 +54,9 @@ plot_sep(m.Z.5)
Z.FOCUS <- mkinmod(Z0 = mkinsub("SFO", "Z1", sink = FALSE),
Z1 = mkinsub("SFO", "Z2", sink = FALSE),
Z2 = mkinsub("SFO", "Z3"),
- Z3 = mkinsub("SFO"),
+ Z3 = mkinsub("SFO"),
use_of_ff = "max")
-m.Z.FOCUS <- mkinfit(Z.FOCUS, FOCUS_2006_Z_mkin,
+m.Z.FOCUS <- mkinfit(Z.FOCUS, FOCUS_2006_Z_mkin,
parms.ini = m.Z.5$bparms.ode,
quiet = TRUE)
plot_sep(m.Z.FOCUS)
@@ -62,7 +84,7 @@ Z.mkin.4 <- mkinmod(Z0 = mkinsub("SFORB", "Z1", sink = FALSE),
Z1 = mkinsub("SFO", "Z2", sink = FALSE),
Z2 = mkinsub("SFO", "Z3"),
Z3 = mkinsub("SFO"))
-m.Z.mkin.4 <- mkinfit(Z.mkin.4, FOCUS_2006_Z_mkin,
+m.Z.mkin.4 <- mkinfit(Z.mkin.4, FOCUS_2006_Z_mkin,
parms.ini = m.Z.mkin.3$bparms.ode,
quiet = TRUE)
plot_sep(m.Z.mkin.4)
@@ -72,13 +94,13 @@ Z.mkin.5 <- mkinmod(Z0 = mkinsub("SFORB", "Z1", sink = FALSE),
Z1 = mkinsub("SFO", "Z2", sink = FALSE),
Z2 = mkinsub("SFO", "Z3"),
Z3 = mkinsub("SFORB"))
-m.Z.mkin.5 <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
+m.Z.mkin.5 <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
parms.ini = m.Z.mkin.4$bparms.ode[1:4],
quiet = TRUE)
plot_sep(m.Z.mkin.5)
## ----FOCUS_2006_Z_fits_11a, echo=TRUE-------------------------------
-m.Z.mkin.5a <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
+m.Z.mkin.5a <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
parms.ini = c(m.Z.mkin.5$bparms.ode[1:7],
k_Z3_bound_free = 0),
fixed_parms = "k_Z3_bound_free",
diff --git a/docs/articles/FOCUS_Z.Rnw b/docs/articles/FOCUS_Z.Rnw
index 5a66db24..5abda0e1 100644
--- a/docs/articles/FOCUS_Z.Rnw
+++ b/docs/articles/FOCUS_Z.Rnw
@@ -3,7 +3,7 @@
\documentclass[12pt,a4paper]{article}
\usepackage{a4wide}
\input{header}
-\hypersetup{
+\hypersetup{
pdftitle = {Example evaluation of FOCUS dataset Z},
pdfsubject = {Manuscript},
pdfauthor = {Johannes Ranke},
@@ -50,15 +50,15 @@ report \citep{FOCUSkinetics2011}, p.350.
require(mkin)
LOD = 0.5
FOCUS_2006_Z = data.frame(
- t = c(0, 0.04, 0.125, 0.29, 0.54, 1, 2, 3, 4, 7, 10, 14, 21,
+ t = c(0, 0.04, 0.125, 0.29, 0.54, 1, 2, 3, 4, 7, 10, 14, 21,
42, 61, 96, 124),
- Z0 = c(100, 81.7, 70.4, 51.1, 41.2, 6.6, 4.6, 3.9, 4.6, 4.3, 6.8,
+ Z0 = c(100, 81.7, 70.4, 51.1, 41.2, 6.6, 4.6, 3.9, 4.6, 4.3, 6.8,
2.9, 3.5, 5.3, 4.4, 1.2, 0.7),
- Z1 = c(0, 18.3, 29.6, 46.3, 55.1, 65.7, 39.1, 36, 15.3, 5.6, 1.1,
+ Z1 = c(0, 18.3, 29.6, 46.3, 55.1, 65.7, 39.1, 36, 15.3, 5.6, 1.1,
1.6, 0.6, 0.5 * LOD, NA, NA, NA),
- Z2 = c(0, NA, 0.5 * LOD, 2.6, 3.8, 15.3, 37.2, 31.7, 35.6, 14.5,
+ Z2 = c(0, NA, 0.5 * LOD, 2.6, 3.8, 15.3, 37.2, 31.7, 35.6, 14.5,
0.8, 2.1, 1.9, 0.5 * LOD, NA, NA, NA),
- Z3 = c(0, NA, NA, NA, NA, 0.5 * LOD, 9.2, 13.1, 22.3, 28.4, 32.5,
+ Z3 = c(0, NA, NA, NA, NA, 0.5 * LOD, 9.2, 13.1, 22.3, 28.4, 32.5,
25.2, 17.2, 4.8, 4.5, 2.8, 4.4))
FOCUS_2006_Z_mkin <- mkin_wide_to_long(FOCUS_2006_Z)
@@ -66,9 +66,9 @@ FOCUS_2006_Z_mkin <- mkin_wide_to_long(FOCUS_2006_Z)
\section{Parent compound and one metabolite}
-The next step is to set up the models used for the kinetic analysis. As the
+The next step is to set up the models used for the kinetic analysis. As the
simultaneous fit of parent and the first metabolite is usually straightforward,
-Step 1 (SFO for parent only) is skipped here. We start with the model 2a,
+Step 1 (SFO for parent only) is skipped here. We start with the model 2a,
with formation and decline of metabolite Z1 and the pathway from parent
directly to sink included (default in mkin).
@@ -80,15 +80,15 @@ plot_sep(m.Z.2a)
summary(m.Z.2a, data = FALSE)$bpar
@
-As obvious from the parameter summary (the \texttt{bpar} component of the
+As obvious from the parameter summary (the \texttt{bpar} component of the
summary), the kinetic rate constant from parent compound Z to sink
-is negligible. Accordingly, the exact magnitude of the fitted parameter
+is negligible. Accordingly, the exact magnitude of the fitted parameter
\texttt{log k\_Z0\_sink} is ill-defined and the covariance matrix is not
-returned (not shown, would be visible in the complete summary).
+returned (not shown, would be visible in the complete summary).
This suggests, in agreement with the analysis in the FOCUS kinetics report, to
simplify the model by removing the pathway to sink.
-A similar result can be obtained when formation fractions are used in the model
+A similar result can be obtained when formation fractions are used in the model
formulation:
<<FOCUS_2006_Z_fits_2, echo=TRUE, fig.height=6>>=
@@ -104,16 +104,16 @@ summary(m.Z.2a.ff, data = FALSE)$bpar
Here, the ilr transformed formation fraction fitted in the model takes a very
large value, and the backtransformed formation fraction from parent Z to Z1 is
practically unity. Again, the covariance matrix is not returned as the model is
-overparameterised.
+overparameterised.
The simplified model is obtained by setting the list component \texttt{sink} to
\texttt{FALSE}.\footnote{If the model formulation without formation fractions
is used, the same effect can be obtained by fixing the parameter \texttt{k\_Z\_sink}
-to a value of zero.}
+to a value of zero.}
In the following, we use the parameterisation with formation fractions in order
-to be able to compare with the results in the FOCUS guidance, and as it
-makes it easier to use parameters obtained in a previous fit when adding a further
+to be able to compare with the results in the FOCUS guidance, and as it
+makes it easier to use parameters obtained in a previous fit when adding a further
metabolite.
<<FOCUS_2006_Z_fits_3, echo=TRUE, fig.height=6>>=
@@ -130,10 +130,10 @@ to sink, the formation fraction is internally fixed to unity.
\section{Including metabolites Z2 and Z3}
As suggested in the FOCUS report, the pathway to sink was removed for metabolite Z1 as
-well in the next step. While this step appears questionable on the basis of the above results, it
-is followed here for the purpose of comparison. Also, in the FOCUS report, it is
+well in the next step. While this step appears questionable on the basis of the above results, it
+is followed here for the purpose of comparison. Also, in the FOCUS report, it is
assumed that there is additional empirical evidence that Z1 quickly and exclusively
-hydrolyses to Z2.
+hydrolyses to Z2.
<<FOCUS_2006_Z_fits_5, echo=TRUE, fig.height=7>>=
Z.5 <- mkinmod(Z0 = mkinsub("SFO", "Z1", sink = FALSE),
@@ -151,9 +151,9 @@ accelerate the optimization.
Z.FOCUS <- mkinmod(Z0 = mkinsub("SFO", "Z1", sink = FALSE),
Z1 = mkinsub("SFO", "Z2", sink = FALSE),
Z2 = mkinsub("SFO", "Z3"),
- Z3 = mkinsub("SFO"),
+ Z3 = mkinsub("SFO"),
use_of_ff = "max")
-m.Z.FOCUS <- mkinfit(Z.FOCUS, FOCUS_2006_Z_mkin,
+m.Z.FOCUS <- mkinfit(Z.FOCUS, FOCUS_2006_Z_mkin,
parms.ini = m.Z.5$bparms.ode,
quiet = TRUE)
plot_sep(m.Z.FOCUS)
@@ -167,13 +167,13 @@ transformed parameters, however.
\section{Using the SFORB model for parent and metabolites}
-As the FOCUS report states, there is a certain tailing of the time course of metabolite
-Z3. Also, the time course of the parent compound is not fitted very well using the
+As the FOCUS report states, there is a certain tailing of the time course of metabolite
+Z3. Also, the time course of the parent compound is not fitted very well using the
SFO model, as residues at a certain low level remain.
-Therefore, an additional model is offered here, using the single first-order
+Therefore, an additional model is offered here, using the single first-order
reversible binding (SFORB) model for metabolite Z3. As expected, the $\chi^2$
-error level is lower for metabolite Z3 using this model and the graphical
+error level is lower for metabolite Z3 using this model and the graphical
fit for Z3 is improved. However, the covariance matrix is not returned.
<<FOCUS_2006_Z_fits_7, echo=TRUE, fig.height=8>>=
@@ -198,7 +198,7 @@ m.Z.mkin.3 <- mkinfit(Z.mkin.3, FOCUS_2006_Z_mkin, quiet = TRUE)
plot_sep(m.Z.mkin.3)
@
-This results in a much better representation of the behaviour of the parent
+This results in a much better representation of the behaviour of the parent
compound Z0.
Finally, Z3 is added as well. These models appear overparameterised (no
@@ -209,7 +209,7 @@ Z.mkin.4 <- mkinmod(Z0 = mkinsub("SFORB", "Z1", sink = FALSE),
Z1 = mkinsub("SFO", "Z2", sink = FALSE),
Z2 = mkinsub("SFO", "Z3"),
Z3 = mkinsub("SFO"))
-m.Z.mkin.4 <- mkinfit(Z.mkin.4, FOCUS_2006_Z_mkin,
+m.Z.mkin.4 <- mkinfit(Z.mkin.4, FOCUS_2006_Z_mkin,
parms.ini = m.Z.mkin.3$bparms.ode,
quiet = TRUE)
plot_sep(m.Z.mkin.4)
@@ -224,7 +224,7 @@ Z.mkin.5 <- mkinmod(Z0 = mkinsub("SFORB", "Z1", sink = FALSE),
Z1 = mkinsub("SFO", "Z2", sink = FALSE),
Z2 = mkinsub("SFO", "Z3"),
Z3 = mkinsub("SFORB"))
-m.Z.mkin.5 <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
+m.Z.mkin.5 <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
parms.ini = m.Z.mkin.4$bparms.ode[1:4],
quiet = TRUE)
plot_sep(m.Z.mkin.5)
@@ -233,10 +233,10 @@ plot_sep(m.Z.mkin.5)
The summary view of the backtransformed parameters shows that we get no
confidence intervals due to overparameterisation. As the optimized
\texttt{k\_Z3\_bound\_free} is excessively small, it seems reasonable to fix it to
-zero.
+zero.
<<FOCUS_2006_Z_fits_11a, echo=TRUE>>=
-m.Z.mkin.5a <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
+m.Z.mkin.5a <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
parms.ini = c(m.Z.mkin.5$bparms.ode[1:7],
k_Z3_bound_free = 0),
fixed_parms = "k_Z3_bound_free",
@@ -244,7 +244,7 @@ m.Z.mkin.5a <- mkinfit(Z.mkin.5, FOCUS_2006_Z_mkin,
plot_sep(m.Z.mkin.5a)
@
-As expected, the residual plots for Z0 and Z3 are more random than in the case of the
+As expected, the residual plots for Z0 and Z3 are more random than in the case of the
all SFO model for which they were shown above. In conclusion, the model
\texttt{Z.mkin.5a} is proposed as the best-fit model for the dataset from
Appendix 7 of the FOCUS report.
@@ -261,8 +261,8 @@ The endpoints obtained with this model are
endpoints(m.Z.mkin.5a)
@
-It is clear the degradation rate of Z3 towards the end of the experiment
-is very low as DT50\_Z3\_b2 (the second Eigenvalue of the system of two differential
+It is clear the degradation rate of Z3 towards the end of the experiment
+is very low as DT50\_Z3\_b2 (the second Eigenvalue of the system of two differential
equations representing the SFORB system for Z3, corresponding to the slower rate
constant of the DFOP model) is reported to be infinity. However, this appears
to be a feature of the data.
diff --git a/docs/articles/FOCUS_Z.pdf b/docs/articles/FOCUS_Z.pdf
index 6f71d018..6f8929ea 100644
--- a/docs/articles/FOCUS_Z.pdf
+++ b/docs/articles/FOCUS_Z.pdf
Binary files differ
diff --git a/docs/articles/compiled_models.R b/docs/articles/compiled_models.R
index 5ce343cb..dd450e0d 100644
--- a/docs/articles/compiled_models.R
+++ b/docs/articles/compiled_models.R
@@ -15,12 +15,12 @@ SFO_SFO <- mkinmod(
library("microbenchmark")
library("ggplot2")
mb.1 <- microbenchmark(
- "deSolve, not compiled" = mkinfit(SFO_SFO, FOCUS_2006_D,
- solution_type = "deSolve",
+ "deSolve, not compiled" = mkinfit(SFO_SFO, FOCUS_2006_D,
+ solution_type = "deSolve",
use_compiled = FALSE, quiet = TRUE),
- "Eigenvalue based" = mkinfit(SFO_SFO, FOCUS_2006_D,
+ "Eigenvalue based" = mkinfit(SFO_SFO, FOCUS_2006_D,
solution_type = "eigen", quiet = TRUE),
- "deSolve, compiled" = mkinfit(SFO_SFO, FOCUS_2006_D,
+ "deSolve, compiled" = mkinfit(SFO_SFO, FOCUS_2006_D,
solution_type = "deSolve", quiet = TRUE),
times = 3, control = list(warmup = 0))
@@ -38,7 +38,7 @@ FOMC_SFO <- mkinmod(
m1 = mkinsub( "SFO"))
mb.2 <- microbenchmark(
- "deSolve, not compiled" = mkinfit(FOMC_SFO, FOCUS_2006_D,
+ "deSolve, not compiled" = mkinfit(FOMC_SFO, FOCUS_2006_D,
use_compiled = FALSE, quiet = TRUE),
"deSolve, compiled" = mkinfit(FOMC_SFO, FOCUS_2006_D, quiet = TRUE),
times = 3, control = list(warmup = 0))
diff --git a/docs/articles/compiled_models.html b/docs/articles/compiled_models.html
index 153841ae..1446a357 100644
--- a/docs/articles/compiled_models.html
+++ b/docs/articles/compiled_models.html
@@ -41,7 +41,7 @@
<h1>Performance benefit by using compiled model definitions in mkin</h1>
<h4 class="author">Johannes Ranke</h4>
- <h4 class="date">2016-11-04</h4>
+ <h4 class="date">2016-11-17</h4>
</div>
@@ -63,12 +63,12 @@ SFO_SFO &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mki
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">library</span>(<span class="st">"microbenchmark"</span>)
<span class="kw">library</span>(<span class="st">"ggplot2"</span>)
mb<span class="fl">.1</span> &lt;-<span class="st"> </span><span class="kw">microbenchmark</span>(
- <span class="st">"deSolve, not compiled"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(SFO_SFO, FOCUS_2006_D,
- <span class="dt">solution_type =</span> <span class="st">"deSolve"</span>,
+ <span class="st">"deSolve, not compiled"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(SFO_SFO, FOCUS_2006_D,
+ <span class="dt">solution_type =</span> <span class="st">"deSolve"</span>,
<span class="dt">use_compiled =</span> <span class="ot">FALSE</span>, <span class="dt">quiet =</span> <span class="ot">TRUE</span>),
- <span class="st">"Eigenvalue based"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(SFO_SFO, FOCUS_2006_D,
+ <span class="st">"Eigenvalue based"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(SFO_SFO, FOCUS_2006_D,
<span class="dt">solution_type =</span> <span class="st">"eigen"</span>, <span class="dt">quiet =</span> <span class="ot">TRUE</span>),
- <span class="st">"deSolve, compiled"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(SFO_SFO, FOCUS_2006_D,
+ <span class="st">"deSolve, compiled"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(SFO_SFO, FOCUS_2006_D,
<span class="dt">solution_type =</span> <span class="st">"deSolve"</span>, <span class="dt">quiet =</span> <span class="ot">TRUE</span>),
<span class="dt">times =</span> <span class="dv">3</span>, <span class="dt">control =</span> <span class="kw">list</span>(<span class="dt">warmup =</span> <span class="dv">0</span>))</code></pre></div>
<pre><code>## Warning in microbenchmark(`deSolve, not compiled` = mkinfit(SFO_SFO,
@@ -78,21 +78,21 @@ mb<span class="fl">.1</span> &lt;-<span class="st"> </span><span class="kw">micr
<span class="kw">print</span>(mb<span class="fl">.1</span>)</code></pre></div>
<pre><code>## Unit: milliseconds
## expr min lq mean median uq
-## deSolve, not compiled 6282.2220 6293.7637 6323.0479 6305.3053 6343.4608
-## Eigenvalue based 873.2553 886.5949 903.6178 899.9345 918.7990
-## deSolve, compiled 737.7899 738.8794 752.3343 739.9689 759.6065
+## deSolve, not compiled 6251.2433 6291.2435 6315.5160 6331.2438 6347.6524
+## Eigenvalue based 858.2035 903.1770 926.2132 948.1505 960.2181
+## deSolve, compiled 721.0067 739.1361 745.9964 757.2656 758.4913
## max neval cld
-## 6381.6162 3 c
-## 937.6634 3 b
-## 779.2441 3 a</code></pre>
+## 6364.0611 3 c
+## 972.2856 3 b
+## 759.7171 3 a</code></pre>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">autoplot</span>(mb<span class="fl">.1</span>)</code></pre></div>
<p><img src="compiled_models_files/figure-html/benchmark_SFO_SFO-1.png" width="672"></p>
-<p>We see that using the compiled model is by a factor of 8.5 faster than using the R version with the default ode solver, and it is even faster than the Eigenvalue based solution implemented in R which does not need iterative solution of the ODEs:</p>
+<p>We see that using the compiled model is by a factor of 8.4 faster than using the R version with the default ode solver, and it is even faster than the Eigenvalue based solution implemented in R which does not need iterative solution of the ODEs:</p>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">rownames</span>(smb<span class="fl">.1</span>) &lt;-<span class="st"> </span>smb<span class="fl">.1</span>$expr
smb<span class="fl">.1</span>[<span class="st">"median"</span>]/smb<span class="fl">.1</span>[<span class="st">"deSolve, compiled"</span>, <span class="st">"median"</span>]</code></pre></div>
<pre><code>## median
-## deSolve, not compiled 8.521041
-## Eigenvalue based 1.216179
+## deSolve, not compiled 8.360665
+## Eigenvalue based 1.252071
## deSolve, compiled 1.000000</code></pre>
</div>
<div id="model-that-can-not-be-solved-with-eigenvalues" class="section level2">
@@ -103,7 +103,7 @@ smb<span class="fl">.1</span>[<span class="st">"median"</span>]/smb<span class="
<span class="dt">m1 =</span> <span class="kw"><a href="../reference/mkinsub.html">mkinsub</a></span>( <span class="st">"SFO"</span>))</code></pre></div>
<pre><code>## Successfully compiled differential equation model from auto-generated C code.</code></pre>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r">mb<span class="fl">.2</span> &lt;-<span class="st"> </span><span class="kw">microbenchmark</span>(
- <span class="st">"deSolve, not compiled"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(FOMC_SFO, FOCUS_2006_D,
+ <span class="st">"deSolve, not compiled"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(FOMC_SFO, FOCUS_2006_D,
<span class="dt">use_compiled =</span> <span class="ot">FALSE</span>, <span class="dt">quiet =</span> <span class="ot">TRUE</span>),
<span class="st">"deSolve, compiled"</span> =<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(FOMC_SFO, FOCUS_2006_D, <span class="dt">quiet =</span> <span class="ot">TRUE</span>),
<span class="dt">times =</span> <span class="dv">3</span>, <span class="dt">control =</span> <span class="kw">list</span>(<span class="dt">warmup =</span> <span class="dv">0</span>))</code></pre></div>
@@ -114,18 +114,18 @@ smb<span class="fl">.1</span>[<span class="st">"median"</span>]/smb<span class="
<span class="kw">print</span>(mb<span class="fl">.2</span>)</code></pre></div>
<pre><code>## Unit: seconds
## expr min lq mean median uq
-## deSolve, not compiled 13.644880 13.648332 13.835874 13.651784 13.931372
-## deSolve, compiled 1.422381 1.448574 1.495091 1.474767 1.531446
-## max neval cld
-## 14.210959 3 b
-## 1.588125 3 a</code></pre>
+## deSolve, not compiled 13.601046 13.602861 13.619563 13.604676 13.628821
+## deSolve, compiled 1.341581 1.346263 1.348298 1.350944 1.351657
+## max neval cld
+## 13.65297 3 b
+## 1.35237 3 a</code></pre>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r">smb<span class="fl">.2</span>[<span class="st">"median"</span>]/smb<span class="fl">.2</span>[<span class="st">"deSolve, compiled"</span>, <span class="st">"median"</span>]</code></pre></div>
<pre><code>## median
## 1 NA
## 2 NA</code></pre>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">autoplot</span>(mb<span class="fl">.2</span>)</code></pre></div>
<p><img src="compiled_models_files/figure-html/benchmark_FOMC_SFO-1.png" width="672"></p>
-<p>Here we get a performance benefit of a factor of 9.3 using the version of the differential equation model compiled from C code!</p>
+<p>Here we get a performance benefit of a factor of 10.1 using the version of the differential equation model compiled from C code!</p>
<p>This vignette was built with mkin 0.9.44.9000 on</p>
<pre><code>## R version 3.3.2 (2016-10-31)
## Platform: x86_64-pc-linux-gnu (64-bit)
diff --git a/docs/articles/compiled_models_files/figure-html/benchmark_FOMC_SFO-1.png b/docs/articles/compiled_models_files/figure-html/benchmark_FOMC_SFO-1.png
index c52ccd5d..3c3b9c54 100644
--- a/docs/articles/compiled_models_files/figure-html/benchmark_FOMC_SFO-1.png
+++ b/docs/articles/compiled_models_files/figure-html/benchmark_FOMC_SFO-1.png
Binary files differ
diff --git a/docs/articles/compiled_models_files/figure-html/benchmark_SFO_SFO-1.png b/docs/articles/compiled_models_files/figure-html/benchmark_SFO_SFO-1.png
index c89ef9a5..0ec027f1 100644
--- a/docs/articles/compiled_models_files/figure-html/benchmark_SFO_SFO-1.png
+++ b/docs/articles/compiled_models_files/figure-html/benchmark_SFO_SFO-1.png
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_1-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_1-1.pdf
index f2bb6c87..6f5cbd2a 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_1-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_1-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_10-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_10-1.pdf
index 7fbe61ce..a2d3e91e 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_10-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_10-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_11-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_11-1.pdf
index 70067288..9a88c84b 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_11-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_11-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_11a-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_11a-1.pdf
index f5569149..eda22e28 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_11a-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_11a-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_11b-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_11b-1.pdf
index 1cfcf140..be61a972 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_11b-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_11b-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_2-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_2-1.pdf
index 0eae0fb7..25616330 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_2-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_2-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_3-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_3-1.pdf
index 0071dab6..ccb8e23a 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_3-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_3-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_5-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_5-1.pdf
index 093be7dd..9d0949cd 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_5-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_5-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_6-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_6-1.pdf
index c27fc978..020a1ccd 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_6-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_6-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_7-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_7-1.pdf
index dc07202b..a34809c8 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_7-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_7-1.pdf
Binary files differ
diff --git a/docs/articles/figure/FOCUS_2006_Z_fits_9-1.pdf b/docs/articles/figure/FOCUS_2006_Z_fits_9-1.pdf
index 1580ad3b..26c4ff9d 100644
--- a/docs/articles/figure/FOCUS_2006_Z_fits_9-1.pdf
+++ b/docs/articles/figure/FOCUS_2006_Z_fits_9-1.pdf
Binary files differ
diff --git a/docs/articles/mkin.R b/docs/articles/mkin.R
index 175bd33b..67dc3623 100644
--- a/docs/articles/mkin.R
+++ b/docs/articles/mkin.R
@@ -1,22 +1,34 @@
+## ---- include = FALSE----------------------------------------------------
+require(knitr)
+opts_chunk$set(engine='R', tidy=FALSE)
+
## ---- echo = TRUE, cache = TRUE, fig = TRUE, fig.width = 8, fig.height = 7----
-require(mkin)
+library(mkin)
+# Define the kinetic model
m_SFO_SFO_SFO <- mkinmod(parent = mkinsub("SFO", "M1"),
M1 = mkinsub("SFO", "M2"),
- M2 = mkinsub("SFO"),
+ M2 = mkinsub("SFO"),
use_of_ff = "max", quiet = TRUE)
-sampling_times = c(0, 1, 3, 7, 14, 28, 60, 90, 120)
+# Produce model predictions using some arbitrary parameters
+sampling_times = c(0, 1, 3, 7, 14, 28, 60, 90, 120)
d_SFO_SFO_SFO <- mkinpredict(m_SFO_SFO_SFO,
- c(k_parent = 0.03,
- f_parent_to_M1 = 0.5, k_M1 = log(2)/100,
+ c(k_parent = 0.03,
+ f_parent_to_M1 = 0.5, k_M1 = log(2)/100,
f_M1_to_M2 = 0.9, k_M2 = log(2)/50),
c(parent = 100, M1 = 0, M2 = 0),
sampling_times)
-d_SFO_SFO_SFO_err <- add_err(d_SFO_SFO_SFO, function(x) 3, n = 1, seed = 123456789 )
+# Generate a dataset by adding normally distributed errors with
+# standard deviation 3, for two replicates at each sampling time
+d_SFO_SFO_SFO_err <- add_err(d_SFO_SFO_SFO, reps = 2,
+ sdfunc = function(x) 3,
+ n = 1, seed = 123456789 )
+# Fit the model to the dataset
f_SFO_SFO_SFO <- mkinfit(m_SFO_SFO_SFO, d_SFO_SFO_SFO_err[[1]], quiet = TRUE)
+# Plot the results separately for parent and metabolites
plot_sep(f_SFO_SFO_SFO, lpos = c("topright", "bottomright", "bottomright"))
diff --git a/docs/articles/mkin.html b/docs/articles/mkin.html
index 8a24352c..4eed053a 100644
--- a/docs/articles/mkin.html
+++ b/docs/articles/mkin.html
@@ -41,7 +41,7 @@
<h1>mkin - Kinetic evaluation of chemical degradation data</h1>
<h4 class="author">Johannes Ranke</h4>
- <h4 class="date">2016-11-04</h4>
+ <h4 class="date">2016-11-17</h4>
</div>
@@ -51,25 +51,33 @@
<div id="abstract" class="section level1">
<h1 class="hasAnchor"><html><body><a href="#abstract" class="anchor"> </a></body></html>Abstract</h1>
<p>In the regulatory evaluation of chemical substances like plant protection products (pesticides), biocides and other chemicals, degradation data play an important role. For the evaluation of pesticide degradation experiments, detailed guidance has been developed, based on nonlinear optimisation. The <code>R</code> add-on package <code>mkin</code> <span class="citation">(Ranke 2016)</span> implements fitting some of the models recommended in this guidance from within R and calculates some statistical measures for data series within one or more compartments, for parent and metabolites.</p>
-<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">require</span>(mkin)
+<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">library</span>(mkin)
+<span class="co"># Define the kinetic model</span>
m_SFO_SFO_SFO &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mkinmod.html">mkinmod</a></span>(<span class="dt">parent =</span> <span class="kw"><a href="../reference/mkinsub.html">mkinsub</a></span>(<span class="st">"SFO"</span>, <span class="st">"M1"</span>),
<span class="dt">M1 =</span> <span class="kw"><a href="../reference/mkinsub.html">mkinsub</a></span>(<span class="st">"SFO"</span>, <span class="st">"M2"</span>),
- <span class="dt">M2 =</span> <span class="kw"><a href="../reference/mkinsub.html">mkinsub</a></span>(<span class="st">"SFO"</span>),
+ <span class="dt">M2 =</span> <span class="kw"><a href="../reference/mkinsub.html">mkinsub</a></span>(<span class="st">"SFO"</span>),
<span class="dt">use_of_ff =</span> <span class="st">"max"</span>, <span class="dt">quiet =</span> <span class="ot">TRUE</span>)
-sampling_times =<span class="st"> </span><span class="kw">c</span>(<span class="dv">0</span>, <span class="dv">1</span>, <span class="dv">3</span>, <span class="dv">7</span>, <span class="dv">14</span>, <span class="dv">28</span>, <span class="dv">60</span>, <span class="dv">90</span>, <span class="dv">120</span>)
+<span class="co"># Produce model predictions using some arbitrary parameters</span>
+sampling_times =<span class="st"> </span><span class="kw">c</span>(<span class="dv">0</span>, <span class="dv">1</span>, <span class="dv">3</span>, <span class="dv">7</span>, <span class="dv">14</span>, <span class="dv">28</span>, <span class="dv">60</span>, <span class="dv">90</span>, <span class="dv">120</span>)
d_SFO_SFO_SFO &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mkinpredict.html">mkinpredict</a></span>(m_SFO_SFO_SFO,
- <span class="kw">c</span>(<span class="dt">k_parent =</span> <span class="fl">0.03</span>,
- <span class="dt">f_parent_to_M1 =</span> <span class="fl">0.5</span>, <span class="dt">k_M1 =</span> <span class="kw">log</span>(<span class="dv">2</span>)/<span class="dv">100</span>,
+ <span class="kw">c</span>(<span class="dt">k_parent =</span> <span class="fl">0.03</span>,
+ <span class="dt">f_parent_to_M1 =</span> <span class="fl">0.5</span>, <span class="dt">k_M1 =</span> <span class="kw">log</span>(<span class="dv">2</span>)/<span class="dv">100</span>,
<span class="dt">f_M1_to_M2 =</span> <span class="fl">0.9</span>, <span class="dt">k_M2 =</span> <span class="kw">log</span>(<span class="dv">2</span>)/<span class="dv">50</span>),
<span class="kw">c</span>(<span class="dt">parent =</span> <span class="dv">100</span>, <span class="dt">M1 =</span> <span class="dv">0</span>, <span class="dt">M2 =</span> <span class="dv">0</span>),
sampling_times)
-d_SFO_SFO_SFO_err &lt;-<span class="st"> </span><span class="kw"><a href="../reference/add_err.html">add_err</a></span>(d_SFO_SFO_SFO, function(x) <span class="dv">3</span>, <span class="dt">n =</span> <span class="dv">1</span>, <span class="dt">seed =</span> <span class="dv">123456789</span> )
+<span class="co"># Generate a dataset by adding normally distributed errors with</span>
+<span class="co"># standard deviation 3, for two replicates at each sampling time</span>
+d_SFO_SFO_SFO_err &lt;-<span class="st"> </span><span class="kw"><a href="../reference/add_err.html">add_err</a></span>(d_SFO_SFO_SFO, <span class="dt">reps =</span> <span class="dv">2</span>,
+ <span class="dt">sdfunc =</span> function(x) <span class="dv">3</span>,
+ <span class="dt">n =</span> <span class="dv">1</span>, <span class="dt">seed =</span> <span class="dv">123456789</span> )
+<span class="co"># Fit the model to the dataset</span>
f_SFO_SFO_SFO &lt;-<span class="st"> </span><span class="kw"><a href="../reference/mkinfit.html">mkinfit</a></span>(m_SFO_SFO_SFO, d_SFO_SFO_SFO_err[[<span class="dv">1</span>]], <span class="dt">quiet =</span> <span class="ot">TRUE</span>)
+<span class="co"># Plot the results separately for parent and metabolites</span>
<span class="kw"><a href="../reference/plot.mkinfit.html">plot_sep</a></span>(f_SFO_SFO_SFO, <span class="dt">lpos =</span> <span class="kw">c</span>(<span class="st">"topright"</span>, <span class="st">"bottomright"</span>, <span class="st">"bottomright"</span>))</code></pre></div>
<p><img src="mkin_files/figure-html/unnamed-chunk-2-1.png" width="768"></p>
</div>
@@ -129,13 +137,13 @@ f_SFO_SFO_SFO &lt;-<span class="st"> </span><span class="kw"><a href="../referen
<p>&mdash;&mdash;&mdash;. 2014. <em>Generic Guidance for Estimating Persistence and Degradation Kinetics from Environmental Fate Studies on Pesticides in Eu Registration</em>. 1.1 ed. <a href="http://focus.jrc.ec.europa.eu/dk" class="uri">http://focus.jrc.ec.europa.eu/dk</a>.</p>
</div>
<div id="ref-rcore2016">
-<p>R Development Core Team. 2016. <em>R: A Language and Environment for Statistical Computing</em>. Vienna, Austria: R Foundation for Statistical Computing. <a href="http://www.R-project.org" class="uri">http://www.R-project.org</a>.</p>
+<p>R Development Core Team. 2016. <em>R: A Language and Environment for Statistical Computing</em>. Vienna, Austria: R Foundation for Statistical Computing. <a href="https://www.R-project.org" class="uri">https://www.R-project.org</a>.</p>
</div>
<div id="ref-pkg:kinfit">
-<p>Ranke, J. 2015. <em>&lsquo;Kinfit&lsquo;: Routines for Fitting Simple Kinetic Models to Chemical Degradation Data</em>. <a href="http://CRAN.R-project.org/package=kinfit" class="uri">http://CRAN.R-project.org/package=kinfit</a>.</p>
+<p>Ranke, J. 2015. <em>&lsquo;Kinfit&lsquo;: Routines for Fitting Simple Kinetic Models to Chemical Degradation Data</em>. <a href="https://CRAN.R-project.org/package=kinfit" class="uri">https://CRAN.R-project.org/package=kinfit</a>.</p>
</div>
<div id="ref-pkg:mkin">
-<p>&mdash;&mdash;&mdash;. 2016. <em>&lsquo;Mkin&lsquo;: Kinetic Evaluation of Chemical Degradation Data</em>. <a href="http://CRAN.R-project.org/package=mkin" class="uri">http://CRAN.R-project.org/package=mkin</a>.</p>
+<p>&mdash;&mdash;&mdash;. 2016. <em>&lsquo;Mkin&lsquo;: Kinetic Evaluation of Chemical Degradation Data</em>. <a href="https://CRAN.R-project.org/package=mkin" class="uri">https://CRAN.R-project.org/package=mkin</a>.</p>
</div>
<div id="ref-ranke2012">
<p>Ranke, J., and R. Lehmann. 2012. &ldquo;Parameter Reliability in Kinetic Evaluation of Environmental Metabolism Data - Assessment and the Influence of Model Specification.&rdquo; In <em>SETAC World 20-24 May</em>. Berlin.</p>
diff --git a/docs/articles/mkin_cache/html/__packages b/docs/articles/mkin_cache/html/__packages
index 03ece635..ff62e6df 100644
--- a/docs/articles/mkin_cache/html/__packages
+++ b/docs/articles/mkin_cache/html/__packages
@@ -1,13 +1,12 @@
base
-datasets
-utils
-grDevices
-graphics
-stats
knitr
minpack.lm
rootSolve
-methods
inline
-parallel
mkin
+colorout
+setwidth
+nvimcom
+rmarkdown
+microbenchmark
+ggplot2
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.RData b/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.RData
new file mode 100644
index 00000000..b71faa9b
--- /dev/null
+++ b/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.RData
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdb b/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdb
new file mode 100644
index 00000000..3745afaa
--- /dev/null
+++ b/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdb
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdx b/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdx
new file mode 100644
index 00000000..12116e2c
--- /dev/null
+++ b/docs/articles/mkin_cache/html/unnamed-chunk-2_160d963eca06fe4baa61a0a422a1ea70.rdx
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.RData b/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.RData
deleted file mode 100644
index d11ccf31..00000000
--- a/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.RData
+++ /dev/null
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdb b/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdb
deleted file mode 100644
index 5ac4f484..00000000
--- a/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdb
+++ /dev/null
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdx b/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdx
deleted file mode 100644
index 8983f69e..00000000
--- a/docs/articles/mkin_cache/html/unnamed-chunk-2_60bc93a2c97228ef4815e972498edefa.rdx
+++ /dev/null
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.RData b/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.RData
deleted file mode 100644
index e52d9b7b..00000000
--- a/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.RData
+++ /dev/null
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdb b/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdb
deleted file mode 100644
index ff7ed49e..00000000
--- a/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdb
+++ /dev/null
Binary files differ
diff --git a/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdx b/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdx
deleted file mode 100644
index 7ec72c33..00000000
--- a/docs/articles/mkin_cache/html/unnamed-chunk-2_f17bce9fa804585d9877abdce3dac24a.rdx
+++ /dev/null
Binary files differ
diff --git a/docs/articles/mkin_files/figure-html/unnamed-chunk-2-1.png b/docs/articles/mkin_files/figure-html/unnamed-chunk-2-1.png
index 2e7e2244..d34e3805 100644
--- a/docs/articles/mkin_files/figure-html/unnamed-chunk-2-1.png
+++ b/docs/articles/mkin_files/figure-html/unnamed-chunk-2-1.png
Binary files differ
diff --git a/docs/articles/references.bib b/docs/articles/references.bib
index da51602f..b465f828 100644
--- a/docs/articles/references.bib
+++ b/docs/articles/references.bib
@@ -47,7 +47,7 @@
address = {Vienna, Austria},
year = {2016},
note = {{ISBN} 3-900051-07-0},
- url = {http://www.R-project.org}
+ url = {https://www.R-project.org}
}
@MANUAL{pkg:kinfit,
@@ -55,14 +55,14 @@
degradation data},
author = {J. Ranke},
year = {2015},
- url = {http://CRAN.R-project.org/package=kinfit}
+ url = {https://CRAN.R-project.org/package=kinfit}
}
@MANUAL{pkg:mkin,
title = {`mkin`: {K}inetic evaluation of chemical degradation data},
author = {J. Ranke},
year = {2016},
- url = {http://CRAN.R-project.org/package=mkin}
+ url = {https://CRAN.R-project.org/package=mkin}
}
@Inproceedings{ schaefer2007,
diff --git a/docs/index.html b/docs/index.html
index a3a0e46c..444b650e 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -44,7 +44,7 @@
<div id="installation" class="section level2">
<h2 class="hasAnchor">
<a href="#installation" class="anchor"> </a>Installation</h2>
-<p>You can install the latest released version from <a href="http://cran.r-project.org/package=mkin">CRAN</a> from within R:</p>
+<p>You can install the latest released version from <a href="https://cran.r-project.org/package=mkin">CRAN</a> from within R:</p>
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw">install.packages</span>(<span class="st">"mkin"</span>)</code></pre></div>
</div>
<div id="background" class="section level2">
@@ -93,10 +93,10 @@
<p><code>mkin</code> would not be possible without the underlying software stack consisting of R and the packages <a href="http://cran.r-project.org/package=deSolve">deSolve</a> and <a href="http://cran.r-project.org/package=FME">FME</a>, to say the least.</p>
<p>It could not have been written without me being introduced to regulatory fate modelling of pesticides by Adrian Gurney during my time at Harlan Laboratories Ltd (formerly RCC Ltd). <code>mkin</code> greatly profits from and largely follows the work done by the <a href="http://focus.jrc.ec.europa.eu/dk">FOCUS Degradation Kinetics Workgroup</a>, as detailed in their guidance document from 2006, slightly updated in 2011 and in 2014.</p>
<p>Also, it was inspired by the first version of KinGUI developed by BayerCropScience, which is based on the MatLab runtime environment.</p>
-<p>The companion package <a href="http://kinfit.r-forge.r-project.org/kinfit_static/index.html">kinfit</a> (now deprecated) was <a href="https://r-forge.r-project.org/scm/viewvc.php?view=rev&amp;root=kinfit&amp;revision=2">started in 2008</a> and <a href="http://cran.r-project.org/src/contrib/Archive/kinfit/">first published</a> on CRAN on 01 May 2010.</p>
+<p>The companion package <a href="http://kinfit.r-forge.r-project.org/kinfit_static/index.html">kinfit</a> (now deprecated) was <a href="https://r-forge.r-project.org/scm/viewvc.php?view=rev&amp;root=kinfit&amp;revision=2">started in 2008</a> and <a href="https://cran.r-project.org/src/contrib/Archive/kinfit/">first published</a> on CRAN on 01 May 2010.</p>
<p>The first <code>mkin</code> code was <a href="https://r-forge.r-project.org/scm/viewvc.php?view=rev&amp;root=kinfit&amp;revision=8">published on 11 May 2010</a> and the <a href="http://cran.r-project.org/src/contrib/Archive/mkin">first CRAN version</a> on 18 May 2010.</p>
<p>In 2011, Bayer Crop Science started to distribute an R based successor to KinGUI named KinGUII whose R code is based on <code>mkin</code>, but which added, amongst other refinements, a closed source graphical user interface (GUI), iteratively reweighted least squares (IRLS) optimisation of the variance for each of the observed variables, and Markov Chain Monte Carlo (MCMC) simulation functionality, similar to what is available e.g.&nbsp;in the <code>FME</code> package.</p>
-<p>Somewhat in parallel, Syngenta has sponsored the development of an <code>mkin</code> and KinGUII based GUI application called CAKE, which also adds IRLS and MCMC, is more limited in the model formulation, but puts more weight on usability. CAKE is available for download from the <a href="http://projects.tessella.com/cake">CAKE website</a>, where you can also find a zip archive of the R scripts derived from <code>mkin</code>, published under the GPL license.</p>
+<p>Somewhat in parallel, Syngenta has sponsored the development of an <code>mkin</code> and KinGUII based GUI application called CAKE, which also adds IRLS and MCMC, is more limited in the model formulation, but puts more weight on usability. CAKE is available for download from the <a href="http://showcase.tessella.com/products/cake">CAKE website</a>, where you can also find a zip archive of the R scripts derived from <code>mkin</code>, published under the GPL license.</p>
<p>Finally, there is <a href="http://github.com/zhenglei-gao/KineticEval">KineticEval</a>, which contains a further development of the scripts used for KinGUII, so the different tools will hopefully be able to learn from each other in the future as well.</p>
</div>
<div id="development" class="section level2">
@@ -115,7 +115,7 @@
<p>GPL</p>
<h2>Developers</h2><ul class="list-unstyled"><li>Johannes Ranke <br><small class="roles"> Author, maintainer, copyright&nbsp;holder </small> </li>
<li><a href="authors.html">All authors...</a></li>
-</ul><html><body><h2>Dev status</h2><ul class="list-unstyled"><li><a href="http://cran.r-project.org/package=mkin">
+</ul><html><body><h2>Dev status</h2><ul class="list-unstyled"><li><a href="https://cran.r-project.org/package=mkin">
<img src="http://www.r-pkg.org/badges/version/mkin"></a></li>
</ul></body></html></div>
</div>
diff --git a/docs/reference/Extract.mmkin.html b/docs/reference/Extract.mmkin.html
index 4b6545db..b437fc7d 100644
--- a/docs/reference/Extract.mmkin.html
+++ b/docs/reference/Extract.mmkin.html
@@ -98,7 +98,7 @@
<dt>...</dt>
<dd>Not used, only there to satisfy the generic method definition</dd>
<dt>drop</dt>
- <dd>If FALSE, the method always returns an mmkin object, otherwise either
+ <dd>If FALSE, the method always returns an mmkin object, otherwise either
a list of mkinfit objects or a single mkinfit object.</dd>
</dl>
@@ -193,7 +193,7 @@
#&gt;
#&gt; $time
#&gt; user system elapsed
-#&gt; 0.260 0.000 0.261
+#&gt; 0.268 0.000 0.267
#&gt;
#&gt; $mkinmod
#&gt; &lt;mkinmod&gt; model generated with
@@ -379,7 +379,7 @@
#&gt; }
#&gt; return(mC)
#&gt; }
-#&gt; &lt;environment: 0x5bbb4a8&gt;
+#&gt; &lt;environment: 0x3a2f9e8&gt;
#&gt;
#&gt; $cost_notrans
#&gt; function (P)
@@ -401,7 +401,7 @@
#&gt; scaleVar = scaleVar)
#&gt; return(mC)
#&gt; }
-#&gt; &lt;environment: 0x5bbb4a8&gt;
+#&gt; &lt;environment: 0x3a2f9e8&gt;
#&gt;
#&gt; $hessian_notrans
#&gt; parent_0 alpha beta
@@ -467,7 +467,7 @@
#&gt; 99.66619
#&gt;
#&gt; $date
-#&gt; [1] &quot;Fri Nov 4 17:12:26 2016&quot;
+#&gt; [1] &quot;Thu Nov 17 22:56:49 2016&quot;
#&gt;
#&gt; attr(,&quot;class&quot;)
#&gt; [1] &quot;mkinfit&quot; &quot;modFit&quot; </div><div class='input'> <span class='no'>fits</span>[<span class='st'>"SFO"</span>, <span class='st'>"B"</span>]</div><div class='output co'>#&gt; dataset
@@ -546,7 +546,7 @@
#&gt;
#&gt; $time
#&gt; user system elapsed
-#&gt; 0.068 0.000 0.071
+#&gt; 0.116 0.000 0.115
#&gt;
#&gt; $mkinmod
#&gt; &lt;mkinmod&gt; model generated with
@@ -733,7 +733,7 @@
#&gt; }
#&gt; return(mC)
#&gt; }
-#&gt; &lt;environment: 0x5719c08&gt;
+#&gt; &lt;environment: 0x42fb560&gt;
#&gt;
#&gt; $cost_notrans
#&gt; function (P)
@@ -755,7 +755,7 @@
#&gt; scaleVar = scaleVar)
#&gt; return(mC)
#&gt; }
-#&gt; &lt;environment: 0x5719c08&gt;
+#&gt; &lt;environment: 0x42fb560&gt;
#&gt;
#&gt; $hessian_notrans
#&gt; parent_0 k_parent_sink
@@ -818,7 +818,7 @@
#&gt; 99.17407
#&gt;
#&gt; $date
-#&gt; [1] &quot;Fri Nov 4 17:12:26 2016&quot;
+#&gt; [1] &quot;Thu Nov 17 22:56:48 2016&quot;
#&gt;
#&gt; attr(,&quot;class&quot;)
#&gt; [1] &quot;mkinfit&quot; &quot;modFit&quot; </div><div class='input'> <span class='no'>fits</span>[<span class='st'>"SFO"</span>, <span class='st'>"B"</span>, <span class='kw'>drop</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>]</div><div class='output co'>#&gt; [[1]]
@@ -894,7 +894,7 @@
#&gt;
#&gt; $time
#&gt; user system elapsed
-#&gt; 0.068 0.000 0.071
+#&gt; 0.116 0.000 0.115
#&gt;
#&gt; $mkinmod
#&gt; &lt;mkinmod&gt; model generated with
@@ -1081,7 +1081,7 @@
#&gt; }
#&gt; return(mC)
#&gt; }
-#&gt; &lt;environment: 0x5719c08&gt;
+#&gt; &lt;environment: 0x42fb560&gt;
#&gt;
#&gt; $cost_notrans
#&gt; function (P)
@@ -1103,7 +1103,7 @@
#&gt; scaleVar = scaleVar)
#&gt; return(mC)
#&gt; }
-#&gt; &lt;environment: 0x5719c08&gt;
+#&gt; &lt;environment: 0x42fb560&gt;
#&gt;
#&gt; $hessian_notrans
#&gt; parent_0 k_parent_sink
@@ -1166,7 +1166,7 @@
#&gt; 99.17407
#&gt;
#&gt; $date
-#&gt; [1] &quot;Fri Nov 4 17:12:26 2016&quot;
+#&gt; [1] &quot;Thu Nov 17 22:56:48 2016&quot;
#&gt;
#&gt; attr(,&quot;class&quot;)
#&gt; [1] &quot;mkinfit&quot; &quot;modFit&quot;
diff --git a/docs/reference/add_err.html b/docs/reference/add_err.html
index 0a126c5c..8f1e1abb 100644
--- a/docs/reference/add_err.html
+++ b/docs/reference/add_err.html
@@ -121,7 +121,7 @@
</dd>
<dt>seed</dt>
<dd>
- The seed used for the generation of random numbers. If NA, the seed
+ The seed used for the generation of random numbers. If NA, the seed
is not set.
</dd>
</dl>
@@ -129,7 +129,7 @@
<h2 class="hasAnchor" id="value"><a class="anchor" href="#value"></a>Value</h2>
<p>A list of datasets compatible with <code><a href='mmkin.html'>mmkin</a></code>, i.e.
- the components of the list are datasets compatible with
+ the components of the list are datasets compatible with
<code><a href='mkinfit.html'>mkinfit</a></code>.</p>
<h2 class="hasAnchor" id="references"><a class="anchor" href="#references"></a>References</h2>
diff --git a/docs/reference/endpoints.html b/docs/reference/endpoints.html
index 44a8f4c4..990ceadf 100644
--- a/docs/reference/endpoints.html
+++ b/docs/reference/endpoints.html
@@ -82,8 +82,8 @@
<p>This function calculates DT50 and DT90 values as well as formation fractions from kinetic models
-fitted with mkinfit. If the SFORB model was specified for one of the parents or metabolites,
-the Eigenvalues are returned. These are equivalent to the rate constantes of the DFOP model, but
+fitted with mkinfit. If the SFORB model was specified for one of the parents or metabolites,
+the Eigenvalues are returned. These are equivalent to the rate constantes of the DFOP model, but
with the advantage that the SFORB model can also be used for metabolites.</p>
diff --git a/docs/reference/ilr.html b/docs/reference/ilr.html
index 95fed72e..1e50e216 100644
--- a/docs/reference/ilr.html
+++ b/docs/reference/ilr.html
@@ -98,7 +98,7 @@
<h2 class="hasAnchor" id="value"><a class="anchor" href="#value"></a>Value</h2>
- <p>The result of the forward or backward transformation. The returned components always
+ <p>The result of the forward or backward transformation. The returned components always
sum to 1 for the case of the inverse log-ratio transformation.</p>
<h2 class="hasAnchor" id="references"><a class="anchor" href="#references"></a>References</h2>
diff --git a/docs/reference/mccall81_245T.html b/docs/reference/mccall81_245T.html
index 40c21d3c..4314c84e 100644
--- a/docs/reference/mccall81_245T.html
+++ b/docs/reference/mccall81_245T.html
@@ -122,18 +122,18 @@
<span class='kw'>fixed_parms</span> <span class='kw'>=</span> <span class='st'>"k_phenol_sink"</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)
<span class='fu'>summary</span>(<span class='no'>fit.2</span>, <span class='kw'>data</span> <span class='kw'>=</span> <span class='fl'>FALSE</span>)</div><div class='output co'>#&gt; mkin version: 0.9.44.9000
#&gt; R version: 3.3.2
-#&gt; Date of fit: Fri Nov 4 17:12:32 2016
-#&gt; Date of summary: Fri Nov 4 17:12:32 2016
+#&gt; Date of fit: Thu Nov 17 22:56:55 2016
+#&gt; Date of summary: Thu Nov 17 22:56:55 2016
#&gt;
#&gt; Equations:
-#&gt; d_T245 = - k_T245_sink * T245 - k_T245_phenol * T245
-#&gt; d_phenol = + k_T245_phenol * T245 - k_phenol_sink * phenol -
+#&gt; d_T245/dt = - k_T245_sink * T245 - k_T245_phenol * T245
+#&gt; d_phenol/dt = + k_T245_phenol * T245 - k_phenol_sink * phenol -
#&gt; k_phenol_anisole * phenol
-#&gt; d_anisole = + k_phenol_anisole * phenol - k_anisole_sink * anisole
+#&gt; d_anisole/dt = + k_phenol_anisole * phenol - k_anisole_sink * anisole
#&gt;
#&gt; Model predictions using solution type deSolve
#&gt;
-#&gt; Fitted with method Port using 246 model solutions performed in 1.502 s
+#&gt; Fitted with method Port using 246 model solutions performed in 1.457 s
#&gt;
#&gt; Weighting: none
#&gt;
diff --git a/docs/reference/mkin_long_to_wide.html b/docs/reference/mkin_long_to_wide.html
index fa131a6d..095468e4 100644
--- a/docs/reference/mkin_long_to_wide.html
+++ b/docs/reference/mkin_long_to_wide.html
@@ -81,8 +81,8 @@
</div>
- <p>This function takes a dataframe in the long form as required by <code>modCost</code>
- and converts it into a dataframe with one independent variable and several
+ <p>This function takes a dataframe in the long form as required by <code>modCost</code>
+ and converts it into a dataframe with one independent variable and several
dependent variables as columns.</p>
@@ -92,8 +92,8 @@
<dl class="dl-horizontal">
<dt>long_data</dt>
<dd>
- The dataframe must contain one variable called &quot;time&quot; with the time values specified by the
- <code>time</code> argument, one column called &quot;name&quot; with the grouping of the observed values, and
+ The dataframe must contain one variable called &quot;time&quot; with the time values specified by the
+ <code>time</code> argument, one column called &quot;name&quot; with the grouping of the observed values, and
finally one column of observed values called &quot;value&quot;.
</dd>
<dt>time</dt>
diff --git a/docs/reference/mkin_wide_to_long.html b/docs/reference/mkin_wide_to_long.html
index 077c0b7d..3b2d46e5 100644
--- a/docs/reference/mkin_wide_to_long.html
+++ b/docs/reference/mkin_wide_to_long.html
@@ -81,7 +81,7 @@
</div>
- <p>This function simply takes a dataframe with one independent variable and several
+ <p>This function simply takes a dataframe with one independent variable and several
dependent variable and converts it into the long form as required by <code>modCost</code>.</p>
@@ -91,7 +91,7 @@
<dl class="dl-horizontal">
<dt>wide_data</dt>
<dd>
- The dataframe must contain one variable with the time values specified by the
+ The dataframe must contain one variable with the time values specified by the
<code>time</code> argument and usually more than one column of observed values.
</dd>
<dt>time</dt>
diff --git a/docs/reference/mkinfit.html b/docs/reference/mkinfit.html
index 32083843..891bc18b 100644
--- a/docs/reference/mkinfit.html
+++ b/docs/reference/mkinfit.html
@@ -82,11 +82,11 @@
<p>This function uses the Flexible Modelling Environment package
- <code>FME</code> to create a function calculating the model cost, i.e. the
+ <code>FME</code> to create a function calculating the model cost, i.e. the
deviation between the kinetic model and the observed data. This model cost is
- then minimised using the Port algorithm <code>nlminb</code>,
+ then minimised using the Port algorithm <code>nlminb</code>,
using the specified initial or fixed parameters and starting values.
- Per default, parameters in the kinetic models are internally transformed in order
+ Per default, parameters in the kinetic models are internally transformed in order
to better satisfy the assumption of a normal distribution of their estimators.
In each step of the optimsation, the kinetic model is solved using the
function <code><a href='mkinpredict.html'>mkinpredict</a></code>. The variance of the residuals for each
@@ -200,13 +200,13 @@
</dd>
<dt>use_compiled</dt>
<dd>
- If set to <code>FALSE</code>, no compiled version of the <code><a href='mkinmod.html'>mkinmod</a></code>
+ If set to <code>FALSE</code>, no compiled version of the <code><a href='mkinmod.html'>mkinmod</a></code>
model is used, in the calls to <code><a href='mkinpredict.html'>mkinpredict</a></code> even if
- a compiled verion is present.
+ a compiled verion is present.
</dd>
<dt>method.modFit</dt>
<dd>
- The optimisation method passed to <code>modFit</code>.
+ The optimisation method passed to <code>modFit</code>.
In order to optimally deal with problems where local minima occur, the
&quot;Port&quot; algorithm is now used per default as it is less prone to get trapped
@@ -228,20 +228,20 @@
<dt>maxit.modFit</dt>
<dd>
Maximum number of iterations in the optimisation. If not &quot;auto&quot;, this will
- be passed to the method called by <code>modFit</code>, overriding
+ be passed to the method called by <code>modFit</code>, overriding
what may be specified in the next argument <code>control.modFit</code>.
</dd>
<dt>control.modFit</dt>
<dd>
Additional arguments passed to the optimisation method used by
- <code>modFit</code>.
+ <code>modFit</code>.
</dd>
<dt>transform_rates</dt>
<dd>
Boolean specifying if kinetic rate constants should be transformed in the
model specification used in the fitting for better compliance with the
- assumption of normal distribution of the estimator. If TRUE, also
- alpha and beta parameters of the FOMC model are log-transformed, as well
+ assumption of normal distribution of the estimator. If TRUE, also
+ alpha and beta parameters of the FOMC model are log-transformed, as well
as k1 and k2 rate constants for the DFOP and HS models and the break point
tb of the HS model.
If FALSE, zero is used as a lower bound for the rates in the optimisation.
@@ -250,7 +250,7 @@
<dd>
Boolean specifying if formation fractions constants should be transformed in the
model specification used in the fitting for better compliance with the
- assumption of normal distribution of the estimator. The default (TRUE) is
+ assumption of normal distribution of the estimator. The default (TRUE) is
to do transformations. If TRUE, the g parameter of the DFOP and HS
models are also transformed, as they can also be seen as compositional
data. The transformation used for these transformations is the
@@ -294,7 +294,7 @@
<dd>
The length of the dataseries that is produced by the model prediction
function <code><a href='mkinpredict.html'>mkinpredict</a></code>. This impacts the accuracy of
- the numerical solver if that is used (see <code>solution_type</code> argument.
+ the numerical solver if that is used (see <code>solution_type</code> argument.
The default value is 100.
</dd>
<dt>reweight.method</dt>
@@ -302,9 +302,9 @@
The method used for iteratively reweighting residuals, also known
as iteratively reweighted least squares (IRLS). Default is NULL,
the other method implemented is called &quot;obs&quot;, meaning that each
- observed variable is assumed to have its own variance, this is
+ observed variable is assumed to have its own variance, this is
estimated from the fit and used for weighting the residuals
- in each iteration until convergence of this estimate up to
+ in each iteration until convergence of this estimate up to
<code>reweight.tol</code> or up to the maximum number of iterations
specified by <code>reweight.max.iter</code>.
</dd>
@@ -323,20 +323,20 @@
</dd>
<dt>&amp;#8230;</dt>
<dd>
- Further arguments that will be passed to <code>modFit</code>.
+ Further arguments that will be passed to <code>modFit</code>.
</dd>
</dl>
<h2 class="hasAnchor" id="value"><a class="anchor" href="#value"></a>Value</h2>
- <p>A list with &quot;mkinfit&quot; and &quot;modFit&quot; in the class attribute.
+ <p>A list with &quot;mkinfit&quot; and &quot;modFit&quot; in the class attribute.
A summary can be obtained by <code><a href='summary.mkinfit.html'>summary.mkinfit</a></code>.</p>
<h2 class="hasAnchor" id="see-also"><a class="anchor" href="#see-also"></a>See also</h2>
<p>Plotting methods <code><a href='plot.mkinfit.html'>plot.mkinfit</a></code> and
<code><a href='mkinparplot.html'>mkinparplot</a></code>.</p>
- <p>Fitting of several models to several datasets in a single call to
+ <p>Fitting of several models to several datasets in a single call to
<code><a href='mmkin.html'>mmkin</a></code>.</p>
<h2 class="hasAnchor" id="note"><a class="anchor" href="#note"></a>Note</h2>
@@ -348,7 +348,7 @@
<h2 class="hasAnchor" id="note"><a class="anchor" href="#note"></a>Note</h2>
- <p>When using the &quot;IORE&quot; submodel for metabolites, fitting with
+ <p>When using the &quot;IORE&quot; submodel for metabolites, fitting with
&quot;transform_rates = TRUE&quot; (the default) often leads to failures of the
numerical ODE solver. In this situation it may help to switch off the
internal rate transformation.</p>
@@ -359,15 +359,15 @@
<span class='no'>fit</span> <span class='kw'>&lt;-</span> <span class='fu'>mkinfit</span>(<span class='st'>"FOMC"</span>, <span class='no'>FOCUS_2006_C</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)
<span class='fu'>summary</span>(<span class='no'>fit</span>)</div><div class='output co'>#&gt; mkin version: 0.9.44.9000
#&gt; R version: 3.3.2
-#&gt; Date of fit: Fri Nov 4 17:12:35 2016
-#&gt; Date of summary: Fri Nov 4 17:12:35 2016
+#&gt; Date of fit: Thu Nov 17 22:56:57 2016
+#&gt; Date of summary: Thu Nov 17 22:56:57 2016
#&gt;
#&gt; Equations:
-#&gt; d_parent = - (alpha/beta) * 1/((time/beta) + 1) * parent
+#&gt; d_parent/dt = - (alpha/beta) * 1/((time/beta) + 1) * parent
#&gt;
#&gt; Model predictions using solution type analytical
#&gt;
-#&gt; Fitted with method Port using 64 model solutions performed in 0.147 s
+#&gt; Fitted with method Port using 64 model solutions performed in 0.158 s
#&gt;
#&gt; Weighting: none
#&gt;
@@ -436,7 +436,7 @@
<span class='kw'>m1</span> <span class='kw'>=</span> <span class='fu'><a href='mkinsub.html'>mkinsub</a></span>(<span class='st'>"SFO"</span>))</div><div class='output co'>#&gt; <span class='message'>Successfully compiled differential equation model from auto-generated C code.</span></div><div class='input'><span class='co'># Fit the model to the FOCUS example dataset D using defaults</span>
<span class='fu'>print</span>(<span class='fu'>system.time</span>(<span class='no'>fit</span> <span class='kw'>&lt;-</span> <span class='fu'>mkinfit</span>(<span class='no'>SFO_SFO</span>, <span class='no'>FOCUS_2006_D</span>,
<span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='st'>"eigen"</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)))</div><div class='output co'>#&gt; user system elapsed
-#&gt; 1.208 1.256 0.935 </div><div class='input'><span class='fu'>coef</span>(<span class='no'>fit</span>)</div><div class='output co'>#&gt; parent_0 log_k_parent_sink log_k_parent_m1 log_k_m1_sink
+#&gt; 1.168 1.260 0.924 </div><div class='input'><span class='fu'>coef</span>(<span class='no'>fit</span>)</div><div class='output co'>#&gt; parent_0 log_k_parent_sink log_k_parent_m1 log_k_m1_sink
#&gt; 99.59848 -3.03822 -2.98030 -5.24750 </div><div class='input'><span class='fu'><a href='endpoints.html'>endpoints</a></span>(<span class='no'>fit</span>)</div><div class='output co'>#&gt; $ff
#&gt; parent_sink parent_m1 m1_sink
#&gt; 0.485524 0.514476 1.000000
@@ -450,7 +450,7 @@
#&gt; m1 131.760712 437.69961
#&gt; </div><div class='input'><span class='co'>## Not run: ------------------------------------</span>
<span class='co'># # deSolve is slower when no C compiler (gcc) was available during model generation</span>
-<span class='co'># print(system.time(fit.deSolve &lt;- mkinfit(SFO_SFO, FOCUS_2006_D, </span>
+<span class='co'># print(system.time(fit.deSolve &lt;- mkinfit(SFO_SFO, FOCUS_2006_D,</span>
<span class='co'># solution_type = "deSolve")))</span>
<span class='co'># coef(fit.deSolve)</span>
<span class='co'># endpoints(fit.deSolve)</span>
@@ -465,7 +465,7 @@
<span class='co'># fit.FOMC_SFO &lt;- mkinfit(FOMC_SFO, FOCUS_2006_D)</span>
<span class='co'># # Use starting parameters from parent only FOMC fit</span>
<span class='co'># fit.FOMC = mkinfit("FOMC", FOCUS_2006_D, plot=TRUE)</span>
-<span class='co'># fit.FOMC_SFO &lt;- mkinfit(FOMC_SFO, FOCUS_2006_D, </span>
+<span class='co'># fit.FOMC_SFO &lt;- mkinfit(FOMC_SFO, FOCUS_2006_D,</span>
<span class='co'># parms.ini = fit.FOMC$bparms.ode, plot=TRUE)</span>
<span class='co'># </span>
<span class='co'># # Use stepwise fitting, using optimised parameters from parent only fit, SFORB</span>
diff --git a/docs/reference/mkinpredict.html b/docs/reference/mkinpredict.html
index e8302508..9c78d78a 100644
--- a/docs/reference/mkinpredict.html
+++ b/docs/reference/mkinpredict.html
@@ -128,8 +128,8 @@
</dd>
<dt>use_compiled</dt>
<dd>
- If set to <code>FALSE</code>, no compiled version of the <code><a href='mkinmod.html'>mkinmod</a></code>
- model is used, even if is present.
+ If set to <code>FALSE</code>, no compiled version of the <code><a href='mkinmod.html'>mkinmod</a></code>
+ model is used, even if is present.
</dd>
<dt>atol</dt>
<dd>
@@ -144,7 +144,7 @@
<dt>map_output</dt>
<dd>
Boolean to specify if the output should list values for the observed
- variables (default) or for all state variables (if set to FALSE).
+ variables (default) or for all state variables (if set to FALSE).
</dd>
<dt>&amp;#8230;</dt>
<dd>
@@ -275,17 +275,17 @@
<span class='fu'>c</span>(<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fl'>100</span>, <span class='kw'>m1</span> <span class='kw'>=</span> <span class='fl'>0</span>), <span class='fu'>seq</span>(<span class='fl'>0</span>, <span class='fl'>20</span>, <span class='kw'>by</span> <span class='kw'>=</span> <span class='fl'>0.1</span>),
<span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='st'>"eigen"</span>)[<span class='fl'>201</span>,]))</div><div class='output co'>#&gt; time parent m1
#&gt; 201 20 4.978707 27.46227</div><div class='output co'>#&gt; user system elapsed
-#&gt; 0.008 0.016 0.005 </div><div class='input'> <span class='fu'>system.time</span>(
+#&gt; 0.024 0.004 0.004 </div><div class='input'> <span class='fu'>system.time</span>(
<span class='fu'>print</span>(<span class='fu'>mkinpredict</span>(<span class='no'>SFO_SFO</span>, <span class='fu'>c</span>(<span class='kw'>k_parent_m1</span> <span class='kw'>=</span> <span class='fl'>0.05</span>, <span class='kw'>k_parent_sink</span> <span class='kw'>=</span> <span class='fl'>0.1</span>, <span class='kw'>k_m1_sink</span> <span class='kw'>=</span> <span class='fl'>0.01</span>),
<span class='fu'>c</span>(<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fl'>100</span>, <span class='kw'>m1</span> <span class='kw'>=</span> <span class='fl'>0</span>), <span class='fu'>seq</span>(<span class='fl'>0</span>, <span class='fl'>20</span>, <span class='kw'>by</span> <span class='kw'>=</span> <span class='fl'>0.1</span>),
<span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='st'>"deSolve"</span>)[<span class='fl'>201</span>,]))</div><div class='output co'>#&gt; time parent m1
#&gt; 201 20 4.978707 27.46227</div><div class='output co'>#&gt; user system elapsed
-#&gt; 0.000 0.016 0.002 </div><div class='input'> <span class='fu'>system.time</span>(
+#&gt; 0.016 0.004 0.003 </div><div class='input'> <span class='fu'>system.time</span>(
<span class='fu'>print</span>(<span class='fu'>mkinpredict</span>(<span class='no'>SFO_SFO</span>, <span class='fu'>c</span>(<span class='kw'>k_parent_m1</span> <span class='kw'>=</span> <span class='fl'>0.05</span>, <span class='kw'>k_parent_sink</span> <span class='kw'>=</span> <span class='fl'>0.1</span>, <span class='kw'>k_m1_sink</span> <span class='kw'>=</span> <span class='fl'>0.01</span>),
<span class='fu'>c</span>(<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fl'>100</span>, <span class='kw'>m1</span> <span class='kw'>=</span> <span class='fl'>0</span>), <span class='fu'>seq</span>(<span class='fl'>0</span>, <span class='fl'>20</span>, <span class='kw'>by</span> <span class='kw'>=</span> <span class='fl'>0.1</span>),
<span class='kw'>solution_type</span> <span class='kw'>=</span> <span class='st'>"deSolve"</span>, <span class='kw'>use_compiled</span> <span class='kw'>=</span> <span class='fl'>FALSE</span>)[<span class='fl'>201</span>,]))</div><div class='output co'>#&gt; time parent m1
#&gt; 201 20 4.978707 27.46227</div><div class='output co'>#&gt; user system elapsed
-#&gt; 0.036 0.000 0.035 </div></pre>
+#&gt; 0.032 0.000 0.035 </div></pre>
</div>
<div class="col-md-3 hidden-xs hidden-sm" id="sidebar">
<h2>Contents</h2>
diff --git a/docs/reference/mkinsub.html b/docs/reference/mkinsub.html
index 8bb2ce1c..778b9f93 100644
--- a/docs/reference/mkinsub.html
+++ b/docs/reference/mkinsub.html
@@ -81,7 +81,7 @@
</div>
- <p>This is a convenience function to set up the lists used as arguments for
+ <p>This is a convenience function to set up the lists used as arguments for
<code><a href='mkinmod.html'>mkinmod</a></code>.</p>
@@ -91,17 +91,17 @@
<dl class="dl-horizontal">
<dt>submodel</dt>
<dd>
- Character vector of length one to specify the submodel type. See
+ Character vector of length one to specify the submodel type. See
<code><a href='mkinmod.html'>mkinmod</a></code> for the list of allowed submodel names.
</dd>
<dt>to</dt>
<dd>
- Vector of the names of the state variable to which a transformation
+ Vector of the names of the state variable to which a transformation
shall be included in the model.
</dd>
<dt>sink</dt>
<dd>
- Should a pathway to sink be included in the model in addition to the
+ Should a pathway to sink be included in the model in addition to the
pathways to other state variables?
</dd>
<dt>full_name</dt>
diff --git a/docs/reference/mmkin.html b/docs/reference/mmkin.html
index a21a980b..f7f56164 100644
--- a/docs/reference/mmkin.html
+++ b/docs/reference/mmkin.html
@@ -108,12 +108,12 @@
</dd>
<dt>cluster</dt>
<dd>
- A cluster as returned by <code>makeCluster</code> to be used for parallel
+ A cluster as returned by <code>makeCluster</code> to be used for parallel
execution.
</dd>
<dt>&amp;#8230;</dt>
<dd>
- Further arguments that will be passed to <code><a href='mkinfit.html'>mkinfit</a></code>.
+ Further arguments that will be passed to <code><a href='mkinfit.html'>mkinfit</a></code>.
</dd>
</dl>
diff --git a/docs/reference/plot.mkinfit.html b/docs/reference/plot.mkinfit.html
index 52db9bc6..362a4eef 100644
--- a/docs/reference/plot.mkinfit.html
+++ b/docs/reference/plot.mkinfit.html
@@ -82,22 +82,22 @@
<p>Solves the differential equations with the optimised and fixed parameters
- from a previous successful call to <code><a href='mkinfit.html'>mkinfit</a></code> and plots
+ from a previous successful call to <code><a href='mkinfit.html'>mkinfit</a></code> and plots
the observed data together with the solution of the fitted model.</p>
<pre># S3 method for mkinfit
plot(x, fit = x,
obs_vars = names(fit$mkinmod$map),
- xlab = "Time", ylab = "Observed",
+ xlab = "Time", ylab = "Observed",
xlim = range(fit$data$time),
ylim = "default",
- col_obs = 1:length(obs_vars), pch_obs = col_obs,
+ col_obs = 1:length(obs_vars), pch_obs = col_obs,
lty_obs = rep(1, length(obs_vars)),
add = FALSE, legend = !add,
show_residuals = FALSE, maxabs = "auto",
sep_obs = FALSE, rel.height.middle = 0.9,
- lpos = "topright", inset = c(0.05, 0.05),
+ lpos = "topright", inset = c(0.05, 0.05),
show_errmin = FALSE, errmin_digits = 3, &#8230;)
plot_sep(fit, sep_obs = TRUE, show_residuals = TRUE, show_errmin = TRUE, &#8230;)</pre>
@@ -105,7 +105,7 @@ plot_sep(fit, sep_obs = TRUE, show_residuals = TRUE, show_errmin = TRUE, &#8230
<dl class="dl-horizontal">
<dt>x</dt>
<dd>
- Alias for fit introduced for compatibility with the generic S3 method.
+ Alias for fit introduced for compatibility with the generic S3 method.
</dd>
<dt>fit</dt>
<dd>
@@ -113,7 +113,7 @@ plot_sep(fit, sep_obs = TRUE, show_residuals = TRUE, show_errmin = TRUE, &#8230
</dd>
<dt>obs_vars</dt>
<dd>
- A character vector of names of the observed variables for which the
+ A character vector of names of the observed variables for which the
data and the model should be plotted. Defauls to all observed variables
in the model.
</dd>
@@ -157,7 +157,7 @@ plot_sep(fit, sep_obs = TRUE, show_residuals = TRUE, show_errmin = TRUE, &#8230
<dd>
Should residuals be shown? If only one plot of the fits is shown, the
residual plot is in the lower third of the plot? Otherwise, i.e. if
- &quot;sep_obs&quot; is given, the residual plots will be located to the right of
+ &quot;sep_obs&quot; is given, the residual plots will be located to the right of
the plots of the fitted curves.
</dd>
<dt>maxabs</dt>
diff --git a/docs/reference/plot.mmkin.html b/docs/reference/plot.mmkin.html
index eac31273..f171ab5b 100644
--- a/docs/reference/plot.mmkin.html
+++ b/docs/reference/plot.mmkin.html
@@ -82,7 +82,7 @@
<p>When x is a row selected from an mmkin object (<code><a href='[.mmkin.html'>[.mmkin</a></code>), the same model
- fitted for at least one dataset is shown. When it is a column, the fit of at least one model
+ fitted for at least one dataset is shown. When it is a column, the fit of at least one model
to the same dataset is shown.</p>
@@ -136,7 +136,7 @@
<span class='no'>fits</span> <span class='kw'>&lt;-</span> <span class='fu'><a href='mmkin.html'>mmkin</a></span>(<span class='fu'>c</span>(<span class='st'>"FOMC"</span>, <span class='st'>"HS"</span>), <span class='fu'>list</span>(<span class='st'>"FOCUS B"</span> <span class='kw'>=</span> <span class='no'>FOCUS_2006_B</span>, <span class='st'>"FOCUS C"</span> <span class='kw'>=</span> <span class='no'>FOCUS_2006_C</span>),
<span class='kw'>cores</span> <span class='kw'>=</span> <span class='fl'>1</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>, <span class='kw'>method.modFit</span> <span class='kw'>=</span> <span class='st'>"Marq"</span>)
<span class='fu'>plot</span>(<span class='no'>fits</span>[, <span class='st'>"FOCUS C"</span>])</div><img src='plot.mmkin-2.png' alt='' width='540' height='400' /><div class='input'> <span class='fu'>plot</span>(<span class='no'>fits</span>[<span class='st'>"FOMC"</span>, ])</div><img src='plot.mmkin-4.png' alt='' width='540' height='400' /><div class='input'>
- <span class='co'># We can also plot a single fit, if we like the way mmkin works, but then the plot </span>
+ <span class='co'># We can also plot a single fit, if we like the way mmkin works, but then the plot</span>
<span class='co'># height should be smaller than the plot width (this is not possible for the html pages</span>
<span class='co'># generated by staticdocs, as far as I know).</span>
<span class='fu'>plot</span>(<span class='no'>fits</span>[<span class='st'>"FOMC"</span>, <span class='st'>"FOCUS C"</span>]) <span class='co'># same as plot(fits[1, 2])</span></div><img src='plot.mmkin-6.png' alt='' width='540' height='400' /></pre>
diff --git a/docs/reference/summary.mkinfit.html b/docs/reference/summary.mkinfit.html
index 60f7cdf6..8dc57fb7 100644
--- a/docs/reference/summary.mkinfit.html
+++ b/docs/reference/summary.mkinfit.html
@@ -142,15 +142,15 @@
<h2 class="hasAnchor" id="examples"><a class="anchor" href="#examples"></a>Examples</h2>
<pre class="examples"><div class='input'> <span class='fu'>summary</span>(<span class='fu'><a href='mkinfit.html'>mkinfit</a></span>(<span class='fu'><a href='mkinmod.html'>mkinmod</a></span>(<span class='kw'>parent</span> <span class='kw'>=</span> <span class='fu'>list</span>(<span class='kw'>type</span> <span class='kw'>=</span> <span class='st'>"SFO"</span>)), <span class='no'>FOCUS_2006_A</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>))</div><div class='output co'>#&gt; mkin version: 0.9.44.9000
#&gt; R version: 3.3.2
-#&gt; Date of fit: Fri Nov 4 17:12:43 2016
-#&gt; Date of summary: Fri Nov 4 17:12:43 2016
+#&gt; Date of fit: Thu Nov 17 22:57:05 2016
+#&gt; Date of summary: Thu Nov 17 22:57:05 2016
#&gt;
#&gt; Equations:
-#&gt; d_parent = - k_parent_sink * parent
+#&gt; d_parent/dt = - k_parent_sink * parent
#&gt;
#&gt; Model predictions using solution type analytical
#&gt;
-#&gt; Fitted with method Port using 35 model solutions performed in 0.084 s
+#&gt; Fitted with method Port using 35 model solutions performed in 0.085 s
#&gt;
#&gt; Weighting: none
#&gt;
diff --git a/docs/reference/transform_odeparms.html b/docs/reference/transform_odeparms.html
index f455951d..00af0267 100644
--- a/docs/reference/transform_odeparms.html
+++ b/docs/reference/transform_odeparms.html
@@ -81,7 +81,7 @@
</div>
- <p>The transformations are intended to map parameters that should only take
+ <p>The transformations are intended to map parameters that should only take
on restricted values to the full scale of real numbers. For kinetic rate
constants and other paramters that can only take on positive values, a
simple log transformation is used. For compositional parameters, such as
@@ -112,15 +112,15 @@
<dd>
The kinetic model of class <code><a href='mkinmod.html'>mkinmod</a></code>, containing the names of
the model variables that are needed for grouping the formation fractions
- before <code><a href='ilr.html'>ilr</a></code> transformation, the parameter names and
- the information if the pathway to sink is included in the model.
+ before <code><a href='ilr.html'>ilr</a></code> transformation, the parameter names and
+ the information if the pathway to sink is included in the model.
</dd>
<dt>transform_rates</dt>
<dd>
Boolean specifying if kinetic rate constants should be transformed in the
model specification used in the fitting for better compliance with the
- assumption of normal distribution of the estimator. If TRUE, also
- alpha and beta parameters of the FOMC model are log-transformed, as well
+ assumption of normal distribution of the estimator. If TRUE, also
+ alpha and beta parameters of the FOMC model are log-transformed, as well
as k1 and k2 rate constants for the DFOP and HS models and the break point tb
of the HS model.
</dd>
@@ -128,8 +128,8 @@
<dd>
Boolean specifying if formation fractions constants should be transformed in the
model specification used in the fitting for better compliance with the
- assumption of normal distribution of the estimator. The default (TRUE) is
- to do transformations. The g parameter of the DFOP and HS models are also
+ assumption of normal distribution of the estimator. The default (TRUE) is
+ to do transformations. The g parameter of the DFOP and HS models are also
transformed, as they can also be seen as compositional data. The
transformation used for these transformations is the <code><a href='ilr.html'>ilr</a></code>
transformation.
@@ -149,16 +149,16 @@
<span class='no'>fit</span> <span class='kw'>&lt;-</span> <span class='fu'><a href='mkinfit.html'>mkinfit</a></span>(<span class='no'>SFO_SFO</span>, <span class='no'>FOCUS_2006_D</span>, <span class='kw'>quiet</span> <span class='kw'>=</span> <span class='fl'>TRUE</span>)
<span class='fu'>summary</span>(<span class='no'>fit</span>, <span class='kw'>data</span><span class='kw'>=</span><span class='fl'>FALSE</span>) <span class='co'># See transformed and backtransformed parameters</span></div><div class='output co'>#&gt; mkin version: 0.9.44.9000
#&gt; R version: 3.3.2
-#&gt; Date of fit: Fri Nov 4 17:12:44 2016
-#&gt; Date of summary: Fri Nov 4 17:12:44 2016
+#&gt; Date of fit: Thu Nov 17 22:57:06 2016
+#&gt; Date of summary: Thu Nov 17 22:57:06 2016
#&gt;
#&gt; Equations:
-#&gt; d_parent = - k_parent_sink * parent - k_parent_m1 * parent
-#&gt; d_m1 = + k_parent_m1 * parent - k_m1_sink * m1
+#&gt; d_parent/dt = - k_parent_sink * parent - k_parent_m1 * parent
+#&gt; d_m1/dt = + k_parent_m1 * parent - k_m1_sink * m1
#&gt;
#&gt; Model predictions using solution type deSolve
#&gt;
-#&gt; Fitted with method Port using 153 model solutions performed in 0.656 s
+#&gt; Fitted with method Port using 153 model solutions performed in 0.684 s
#&gt;
#&gt; Weighting: none
#&gt;
@@ -224,7 +224,7 @@
#&gt; m1 131.761 437.70</div><div class='input'>
<span class='co'>## Not run: ------------------------------------</span>
<span class='co'># fit.2 &lt;- mkinfit(SFO_SFO, FOCUS_2006_D, transform_rates = FALSE)</span>
-<span class='co'># summary(fit.2, data=FALSE) </span>
+<span class='co'># summary(fit.2, data=FALSE)</span>
<span class='co'>## ---------------------------------------------</span>
<span class='no'>initials</span> <span class='kw'>&lt;-</span> <span class='no'>fit</span>$<span class='no'>start</span>$<span class='no'>value</span>

Contact - Imprint