aboutsummaryrefslogtreecommitdiff
path: root/docs/dev/articles/mkin.html
diff options
context:
space:
mode:
authorJohannes Ranke <jranke@uni-bremen.de>2020-10-15 12:27:40 +0200
committerJohannes Ranke <jranke@uni-bremen.de>2020-10-15 12:27:40 +0200
commit272aba066f0d7502e319b7e7f14009318cd44348 (patch)
treec867903e262cb9514be5e92c4115d7e549b0d9e1 /docs/dev/articles/mkin.html
parentfa8623eec46d2c3ab1f405127493beb1846e4f1e (diff)
Updating docs of current dev version
Diffstat (limited to 'docs/dev/articles/mkin.html')
-rw-r--r--docs/dev/articles/mkin.html45
1 files changed, 23 insertions, 22 deletions
diff --git a/docs/dev/articles/mkin.html b/docs/dev/articles/mkin.html
index 6865fe96..07627029 100644
--- a/docs/dev/articles/mkin.html
+++ b/docs/dev/articles/mkin.html
@@ -32,7 +32,7 @@
</button>
<span class="navbar-brand">
<a class="navbar-link" href="../index.html">mkin</a>
- <span class="version label label-info" data-toggle="tooltip" data-placement="bottom" title="In-development version">0.9.50.3</span>
+ <span class="version label label-info" data-toggle="tooltip" data-placement="bottom" title="In-development version">0.9.50.4</span>
</span>
</div>
@@ -80,7 +80,7 @@
</ul>
<ul class="nav navbar-nav navbar-right">
<li>
- <a href="http://github.com/jranke/mkin/">
+ <a href="https://github.com/jranke/mkin/">
<span class="fab fa fab fa-github fa-lg"></span>
</a>
@@ -101,9 +101,9 @@
<h1 data-toc-skip>Introduction to mkin</h1>
<h4 class="author">Johannes Ranke</h4>
- <h4 class="date">2020-10-08</h4>
+ <h4 class="date">2020-10-15</h4>
- <small class="dont-index">Source: <a href="http://github.com/jranke/mkin/blob/master/vignettes/mkin.rmd"><code>vignettes/mkin.rmd</code></a></small>
+ <small class="dont-index">Source: <a href="https://github.com/jranke/mkin/blob/master/vignettes/mkin.rmd"><code>vignettes/mkin.rmd</code></a></small>
<div class="hidden name"><code>mkin.rmd</code></div>
</div>
@@ -115,34 +115,35 @@
<h1 class="hasAnchor">
<a href="#abstract" class="anchor"></a>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> 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" id="cb1"><html><body><pre class="r"><span class="fu"><a href="https://rdrr.io/r/base/library.html">library</a></span>(<span class="st">"mkin"</span>, <span class="kw">quietly</span> <span class="kw">=</span> <span class="fl">TRUE</span>)
+<div class="sourceCode" id="cb1"><pre class="downlit">
+<span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="st"><a href="https://pkgdown.jrwb.de/mkin/">"mkin"</a></span>, quietly <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span>
<span class="co"># Define the kinetic model</span>
-<span class="no">m_SFO_SFO_SFO</span> <span class="kw">&lt;-</span> <span class="fu"><a href="../reference/mkinmod.html">mkinmod</a></span>(<span class="kw">parent</span> <span class="kw">=</span> <span class="fu"><a href="../reference/mkinsub.html">mkinsub</a></span>(<span class="st">"SFO"</span>, <span class="st">"M1"</span>),
- <span class="kw">M1</span> <span class="kw">=</span> <span class="fu"><a href="../reference/mkinsub.html">mkinsub</a></span>(<span class="st">"SFO"</span>, <span class="st">"M2"</span>),
- <span class="kw">M2</span> <span class="kw">=</span> <span class="fu"><a href="../reference/mkinsub.html">mkinsub</a></span>(<span class="st">"SFO"</span>),
- <span class="kw">use_of_ff</span> <span class="kw">=</span> <span class="st">"max"</span>, <span class="kw">quiet</span> <span class="kw">=</span> <span class="fl">TRUE</span>)
+<span class="va">m_SFO_SFO_SFO</span> <span class="op">&lt;-</span> <span class="fu"><a href="../reference/mkinmod.html">mkinmod</a></span><span class="op">(</span>parent <span class="op">=</span> <span class="fu"><a href="../reference/mkinsub.html">mkinsub</a></span><span class="op">(</span><span class="st">"SFO"</span>, <span class="st">"M1"</span><span class="op">)</span>,
+ M1 <span class="op">=</span> <span class="fu"><a href="../reference/mkinsub.html">mkinsub</a></span><span class="op">(</span><span class="st">"SFO"</span>, <span class="st">"M2"</span><span class="op">)</span>,
+ M2 <span class="op">=</span> <span class="fu"><a href="../reference/mkinsub.html">mkinsub</a></span><span class="op">(</span><span class="st">"SFO"</span><span class="op">)</span>,
+ use_of_ff <span class="op">=</span> <span class="st">"max"</span>, quiet <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span>
<span class="co"># Produce model predictions using some arbitrary parameters</span>
-<span class="no">sampling_times</span> <span class="kw">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></span>(<span class="fl">0</span>, <span class="fl">1</span>, <span class="fl">3</span>, <span class="fl">7</span>, <span class="fl">14</span>, <span class="fl">28</span>, <span class="fl">60</span>, <span class="fl">90</span>, <span class="fl">120</span>)
-<span class="no">d_SFO_SFO_SFO</span> <span class="kw">&lt;-</span> <span class="fu"><a href="../reference/mkinpredict.html">mkinpredict</a></span>(<span class="no">m_SFO_SFO_SFO</span>,
- <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></span>(<span class="kw">k_parent</span> <span class="kw">=</span> <span class="fl">0.03</span>,
- <span class="kw">f_parent_to_M1</span> <span class="kw">=</span> <span class="fl">0.5</span>, <span class="kw">k_M1</span> <span class="kw">=</span> <span class="fu"><a href="https://rdrr.io/r/base/Log.html">log</a></span>(<span class="fl">2</span>)/<span class="fl">100</span>,
- <span class="kw">f_M1_to_M2</span> <span class="kw">=</span> <span class="fl">0.9</span>, <span class="kw">k_M2</span> <span class="kw">=</span> <span class="fu"><a href="https://rdrr.io/r/base/Log.html">log</a></span>(<span class="fl">2</span>)/<span class="fl">50</span>),
- <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></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="kw">M2</span> <span class="kw">=</span> <span class="fl">0</span>),
- <span class="no">sampling_times</span>)
+<span class="va">sampling_times</span> <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></span><span class="op">(</span><span class="fl">0</span>, <span class="fl">1</span>, <span class="fl">3</span>, <span class="fl">7</span>, <span class="fl">14</span>, <span class="fl">28</span>, <span class="fl">60</span>, <span class="fl">90</span>, <span class="fl">120</span><span class="op">)</span>
+<span class="va">d_SFO_SFO_SFO</span> <span class="op">&lt;-</span> <span class="fu"><a href="../reference/mkinpredict.html">mkinpredict</a></span><span class="op">(</span><span class="va">m_SFO_SFO_SFO</span>,
+ <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></span><span class="op">(</span>k_parent <span class="op">=</span> <span class="fl">0.03</span>,
+ f_parent_to_M1 <span class="op">=</span> <span class="fl">0.5</span>, k_M1 <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/Log.html">log</a></span><span class="op">(</span><span class="fl">2</span><span class="op">)</span><span class="op">/</span><span class="fl">100</span>,
+ f_M1_to_M2 <span class="op">=</span> <span class="fl">0.9</span>, k_M2 <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/Log.html">log</a></span><span class="op">(</span><span class="fl">2</span><span class="op">)</span><span class="op">/</span><span class="fl">50</span><span class="op">)</span>,
+ <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></span><span class="op">(</span>parent <span class="op">=</span> <span class="fl">100</span>, M1 <span class="op">=</span> <span class="fl">0</span>, M2 <span class="op">=</span> <span class="fl">0</span><span class="op">)</span>,
+ <span class="va">sampling_times</span><span class="op">)</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>
-<span class="no">d_SFO_SFO_SFO_err</span> <span class="kw">&lt;-</span> <span class="fu"><a href="../reference/add_err.html">add_err</a></span>(<span class="no">d_SFO_SFO_SFO</span>, <span class="kw">reps</span> <span class="kw">=</span> <span class="fl">2</span>,
- <span class="kw">sdfunc</span> <span class="kw">=</span> <span class="kw">function</span>(<span class="no">x</span>) <span class="fl">3</span>,
- <span class="kw">n</span> <span class="kw">=</span> <span class="fl">1</span>, <span class="kw">seed</span> <span class="kw">=</span> <span class="fl">123456789</span> )
+<span class="va">d_SFO_SFO_SFO_err</span> <span class="op">&lt;-</span> <span class="fu"><a href="../reference/add_err.html">add_err</a></span><span class="op">(</span><span class="va">d_SFO_SFO_SFO</span>, reps <span class="op">=</span> <span class="fl">2</span>,
+ sdfunc <span class="op">=</span> <span class="kw">function</span><span class="op">(</span><span class="va">x</span><span class="op">)</span> <span class="fl">3</span>,
+ n <span class="op">=</span> <span class="fl">1</span>, seed <span class="op">=</span> <span class="fl">123456789</span> <span class="op">)</span>
<span class="co"># Fit the model to the dataset</span>
-<span class="no">f_SFO_SFO_SFO</span> <span class="kw">&lt;-</span> <span class="fu"><a href="../reference/mkinfit.html">mkinfit</a></span>(<span class="no">m_SFO_SFO_SFO</span>, <span class="no">d_SFO_SFO_SFO_err</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="va">f_SFO_SFO_SFO</span> <span class="op">&lt;-</span> <span class="fu"><a href="../reference/mkinfit.html">mkinfit</a></span><span class="op">(</span><span class="va">m_SFO_SFO_SFO</span>, <span class="va">d_SFO_SFO_SFO_err</span><span class="op">[[</span><span class="fl">1</span><span class="op">]</span><span class="op">]</span>, quiet <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span>
<span class="co"># Plot the results separately for parent and metabolites</span>
-<span class="fu"><a href="../reference/plot.mkinfit.html">plot_sep</a></span>(<span class="no">f_SFO_SFO_SFO</span>, <span class="kw">lpos</span> <span class="kw">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></span>(<span class="st">"topright"</span>, <span class="st">"bottomright"</span>, <span class="st">"bottomright"</span>))</pre></body></html></div>
+<span class="fu"><a href="../reference/plot.mkinfit.html">plot_sep</a></span><span class="op">(</span><span class="va">f_SFO_SFO_SFO</span>, lpos <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html">c</a></span><span class="op">(</span><span class="st">"topright"</span>, <span class="st">"bottomright"</span>, <span class="st">"bottomright"</span><span class="op">)</span><span class="op">)</span></pre></div>
<p><img src="mkin_files/figure-html/unnamed-chunk-2-1.png" width="768"></p>
</div>
<div id="background" class="section level1">
@@ -248,7 +249,7 @@
</div>
<div class="pkgdown">
- <p>Site built with <a href="https://pkgdown.r-lib.org/">pkgdown</a> 1.5.1.</p>
+ <p>Site built with <a href="https://pkgdown.r-lib.org/">pkgdown</a> 1.6.1.</p>
</div>
</footer>

Contact - Imprint