From e5d1df9a9b1f0951d7dfbaf24eee4294470b73e2 Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Thu, 17 Nov 2022 14:54:20 +0100 Subject: Complete update of online docs for v1.2.0 --- docs/articles/mkin.html | 72 ++++++++++++++++++++++++++----------------------- 1 file changed, 39 insertions(+), 33 deletions(-) (limited to 'docs/articles/mkin.html') diff --git a/docs/articles/mkin.html b/docs/articles/mkin.html index a32f4b41..da499501 100644 --- a/docs/articles/mkin.html +++ b/docs/articles/mkin.html @@ -33,7 +33,7 @@ mkin - 1.1.0 + 1.2.0 @@ -62,11 +62,14 @@ Example evaluations of dimethenamid data from 2018 with nonlinear mixed-effects models
  • - Example evaluation of FOCUS Example Dataset Z + Short demo of the multistart method
  • Performance benefit by using compiled model definitions in mkin
  • +
  • + Example evaluation of FOCUS Example Dataset Z +
  • Calculation of time weighted average concentrations with mkin
  • @@ -74,7 +77,10 @@ Example evaluation of NAFTA SOP Attachment examples
  • - Some benchmark timings + Benchmark timings for mkin +
  • +
  • + Benchmark timings for saem.mmkin
  • @@ -105,7 +111,7 @@

    Introduction to mkin

    Johannes Ranke

    -

    Last change 15 February 2021 (rebuilt 2022-05-18)

    +

    Last change 15 February 2021 (rebuilt 2022-11-17)

    Source: vignettes/mkin.rmd @@ -120,34 +126,34 @@

    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 R add-on package mkin 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.

    -library("mkin", quietly = TRUE)
    -# Define the kinetic model
    -m_SFO_SFO_SFO <- mkinmod(parent = mkinsub("SFO", "M1"),
    -                         M1 = mkinsub("SFO", "M2"),
    -                         M2 = mkinsub("SFO"),
    -                         use_of_ff = "max", quiet = TRUE)
    -
    -
    -# 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,
    -    f_M1_to_M2 = 0.9, k_M2 = log(2)/50),
    -  c(parent = 100, M1 = 0, M2 = 0),
    -  sampling_times)
    -
    -# 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"))
    +library("mkin", quietly = TRUE) +# Define the kinetic model +m_SFO_SFO_SFO <- mkinmod(parent = mkinsub("SFO", "M1"), + M1 = mkinsub("SFO", "M2"), + M2 = mkinsub("SFO"), + use_of_ff = "max", quiet = TRUE) + + +# 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, + f_M1_to_M2 = 0.9, k_M2 = log(2)/50), + c(parent = 100, M1 = 0, M2 = 0), + sampling_times) + +# 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"))

    @@ -264,7 +270,7 @@

    -

    Site built with pkgdown 2.0.3.

    +

    Site built with pkgdown 2.0.6.

    -- cgit v1.2.1