From f59b8a93a9956ac46eac24d294f7a26642b995dc Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Thu, 14 Sep 2017 12:15:58 +0200 Subject: Convert FOCUS Z vignette to rmarkdown/html - Static documentation rebuilt by pkgdown::build_articles() - DESCRIPTION: Version bump and current date --- DESCRIPTION | 4 +- GNUmakefile | 13 +- NEWS.md | 4 + _pkgdown.yml | 2 + docs/articles/FOCUS_D.Rmd | 74 --- docs/articles/FOCUS_D.html | 278 +++++----- docs/articles/FOCUS_D_files/figure-html/plot-1.png | Bin 95834 -> 98934 bytes .../FOCUS_D_files/figure-html/plot_2-1.png | Bin 14059 -> 14308 bytes docs/articles/FOCUS_L.Rmd | 271 --------- docs/articles/FOCUS_L.html | 603 +++++++++------------ .../figure-html/unnamed-chunk-10-1.png | Bin 28716 -> 29157 bytes .../figure-html/unnamed-chunk-12-1.png | Bin 52644 -> 54520 bytes .../figure-html/unnamed-chunk-13-1.png | Bin 21438 -> 21712 bytes .../figure-html/unnamed-chunk-15-1.png | Bin 36854 -> 38347 bytes .../figure-html/unnamed-chunk-4-1.png | Bin 23253 -> 23493 bytes .../figure-html/unnamed-chunk-5-1.png | Bin 14728 -> 14866 bytes .../figure-html/unnamed-chunk-6-1.png | Bin 23593 -> 23975 bytes .../figure-html/unnamed-chunk-8-1.png | Bin 27575 -> 27988 bytes .../figure-html/unnamed-chunk-9-1.png | Bin 28058 -> 28412 bytes docs/articles/FOCUS_Z.html | 339 ++++++++++++ .../figure-html/FOCUS_2006_Z_fits_1-1.png | Bin 0 -> 85456 bytes .../figure-html/FOCUS_2006_Z_fits_10-1.png | Bin 0 -> 128546 bytes .../figure-html/FOCUS_2006_Z_fits_11-1.png | Bin 0 -> 128184 bytes .../figure-html/FOCUS_2006_Z_fits_11a-1.png | Bin 0 -> 101885 bytes .../figure-html/FOCUS_2006_Z_fits_11b-1.png | Bin 0 -> 22682 bytes .../figure-html/FOCUS_2006_Z_fits_2-1.png | Bin 0 -> 86036 bytes .../figure-html/FOCUS_2006_Z_fits_3-1.png | Bin 0 -> 85658 bytes .../figure-html/FOCUS_2006_Z_fits_5-1.png | Bin 0 -> 101539 bytes .../figure-html/FOCUS_2006_Z_fits_6-1.png | Bin 0 -> 129171 bytes .../figure-html/FOCUS_2006_Z_fits_7-1.png | Bin 0 -> 128994 bytes .../figure-html/FOCUS_2006_Z_fits_9-1.png | Bin 0 -> 108245 bytes docs/articles/compiled_models.Rmd | 107 ---- docs/articles/compiled_models.html | 445 ++++++--------- docs/articles/index.html | 14 +- docs/articles/mkin.R | 34 ++ docs/articles/mkin.Rmd | 223 -------- docs/articles/mkin.html | 458 ++++++---------- .../mkin_files/figure-html/unnamed-chunk-2-1.png | Bin 112161 -> 114757 bytes docs/articles/references.bib | 8 +- docs/articles/twa.Rmd | 57 -- docs/articles/twa.html | 252 ++++----- docs/authors.html | 3 + docs/index.html | 3 + docs/news/index.html | 11 + docs/reference/IORE.solution.html | 3 + docs/reference/add_err.html | 3 + docs/reference/endpoints.html | 3 + docs/reference/geometric_mean.html | 3 + docs/reference/ilr.html | 3 + docs/reference/index.html | 5 +- docs/reference/max_twa_parent.html | 3 + docs/reference/mkin_long_to_wide.html | 3 + docs/reference/mkin_wide_to_long.html | 3 + docs/reference/mkinds.html | 3 + docs/reference/mkinparplot.html | 3 + docs/reference/mkinplot.html | 3 + docs/reference/mkinresplot.html | 3 + docs/reference/mkinsub.html | 3 + docs/reference/plot.mkinfit.html | 3 + docs/reference/plot.mmkin.html | 3 + docs/reference/print.mkinds.html | 3 + docs/reference/print.mkinmod.html | 3 + docs/reference/schaefer07_complex_case.html | 3 + vignettes/FOCUS_Z.Rmd | 255 +++++++++ vignettes/FOCUS_Z.Rnw | 274 ---------- vignettes/FOCUS_Z.html | 484 +++++++++++++++++ vignettes/FOCUS_Z.pdf | Bin 240659 -> 0 bytes vignettes/header.tex | 22 - 68 files changed, 2011 insertions(+), 2286 deletions(-) delete mode 100644 docs/articles/FOCUS_D.Rmd delete mode 100644 docs/articles/FOCUS_L.Rmd create mode 100644 docs/articles/FOCUS_Z.html create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_1-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_10-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_11-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_11a-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_11b-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_2-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_3-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_5-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_6-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_7-1.png create mode 100644 docs/articles/FOCUS_Z_files/figure-html/FOCUS_2006_Z_fits_9-1.png delete mode 100644 docs/articles/compiled_models.Rmd create mode 100644 docs/articles/mkin.R delete mode 100644 docs/articles/mkin.Rmd delete mode 100644 docs/articles/twa.Rmd create mode 100644 vignettes/FOCUS_Z.Rmd delete mode 100644 vignettes/FOCUS_Z.Rnw create mode 100644 vignettes/FOCUS_Z.html delete mode 100644 vignettes/FOCUS_Z.pdf delete mode 100644 vignettes/header.tex diff --git a/DESCRIPTION b/DESCRIPTION index ed765897..95fc62a6 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,8 +1,8 @@ Package: mkin Type: Package Title: Kinetic Evaluation of Chemical Degradation Data -Version: 0.9.46.1 -Date: 2017-09-07 +Version: 0.9.46.2 +Date: 2017-09-14 Authors@R: c(person("Johannes", "Ranke", role = c("aut", "cre", "cph"), email = "jranke@uni-bremen.de"), person("Katrin", "Lindenberger", role = "ctb"), diff --git a/GNUmakefile b/GNUmakefile index 24e903a2..c28dc221 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -57,16 +57,8 @@ quickcheck: build-no-vignettes mv $(TGZ) $(TGZVNR) clean: - $(RM) -r vignettes/*.bbl - $(RM) -r vignettes/*.blg - $(RM) -r vignettes/*.fls - $(RM) -r vignettes/*.fdb_latexmk - $(RM) -r vignettes/cache - $(RM) -r vignettes/figure $(RM) -r vignettes/*_cache $(RM) -r vignettes/*_files - $(RM) -r vignettes/*-concordance.tex - $(RM) -r vignettes/*.synctex.gz $(RM) Rplots.pdf test: quickinstall @@ -75,13 +67,10 @@ test: quickinstall README.html: README.md "$(RBIN)/Rscript" -e "rmarkdown::render('README.md', output_format = 'html_document', output_options = list(mathjax = NULL))" -vignettes/%.pdf: vignettes/header.tex vignettes/references.bib vignettes/%.Rnw - "$(RBIN)/Rscript" -e "tools::buildVignette(file = 'vignettes/$*.Rnw', dir = 'vignettes')" - vignettes/%.html: vignettes/mkin_vignettes.css vignettes/references.bib vignettes/%.Rmd "$(RBIN)/Rscript" -e "tools::buildVignette(file = 'vignettes/$*.Rmd', dir = 'vignettes')" -vignettes: vignettes/mkin.html vignettes/FOCUS_D.html vignettes/FOCUS_L.html vignettes/FOCUS_Z.pdf vignettes/compiled_models.html +vignettes: vignettes/mkin.html vignettes/FOCUS_D.html vignettes/FOCUS_L.html vignettes/FOCUS_Z.html vignettes/compiled_models.html pd: "$(RBIN)/Rscript" -e "pkgdown::build_news()" diff --git a/NEWS.md b/NEWS.md index a7bb0e63..55f9dfec 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,7 @@ +# mkin 0.9.46.2 + +- Converted the vignette FOCUS_Z from tex/pdf to markdown/html + # mkin 0.9.46.1 (2017-09-14) - `plot.mkinfit`: Fix scaling of residual plots for the case of separate plots for each observed variable diff --git a/_pkgdown.yml b/_pkgdown.yml index a9e53efb..a2830d67 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -78,6 +78,8 @@ navbar: href: articles/FOCUS_D.html - text: Example evaluation of FOCUS Laboratory Data L1 to L3 href: articles/FOCUS_L.html + - text: Example evaluation of FOCUS Example Dataset Z + href: articles/FOCUS_Z.html - text: Performance benefit by using compiled model definitions in mkin href: articles/compiled_models.html - text: Calculation of time weighted average concentrations with mkin diff --git a/docs/articles/FOCUS_D.Rmd b/docs/articles/FOCUS_D.Rmd deleted file mode 100644 index b4e61a7c..00000000 --- a/docs/articles/FOCUS_D.Rmd +++ /dev/null @@ -1,74 +0,0 @@ ---- -title: Example evaluation of FOCUS Example Dataset D -author: Johannes Ranke -date: "`r Sys.Date()`" -output: - html_document: - mathjax: null - theme: united - fig_retina: null -vignette: > - %\VignetteIndexEntry{Example evaluation of FOCUS Example Dataset D} - %\VignetteEngine{knitr::rmarkdown} - %\VignetteEncoding{UTF-8} ---- - -```{r, include = FALSE} -library(knitr) -opts_chunk$set(tidy = FALSE, cache = TRUE) -``` - -This is just a very simple vignette showing how to fit a degradation model for a parent -compound with one transformation product using `mkin`. After loading the -library we look a the data. We have observed concentrations in the column named -`value` at the times specified in column `time` for the two observed variables -named `parent` and `m1`. - - -```{r data} -library("mkin") -print(FOCUS_2006_D) -``` - -Next we specify the degradation model: The parent compound degrades with simple first-order -kinetics (SFO) to one metabolite named m1, which also degrades with SFO kinetics. - -The call to mkinmod returns a degradation model. The differential equations represented in -R code can be found in the character vector `$diffs` of the `mkinmod` object. If -a C compiler (gcc) is installed and functional, the differential equation model will -be compiled from auto-generated C code. - -```{r model} -SFO_SFO <- mkinmod(parent = mkinsub("SFO", "m1"), m1 = mkinsub("SFO")) -print(SFO_SFO$diffs) -``` - -We do the fitting without progress report (`quiet = TRUE`). - - -```{r fit} -fit <- mkinfit(SFO_SFO, FOCUS_2006_D, quiet = TRUE) -``` - -A plot of the fit including a residual plot for both observed variables is obtained -using the `plot_sep` method for `mkinfit` objects, which shows separate graphs for -all compounds and their residuals. - -```{r plot, fig.height = 6, fig.width = 8} -plot_sep(fit, lpos = c("topright", "bottomright")) -``` - -Confidence intervals for the parameter estimates are obtained using the `mkinparplot` function. - - -```{r plot_2, fig.height = 4, fig.width = 8} -mkinparplot(fit) -``` - -A comprehensive report of the results is obtained using the `summary` method for `mkinfit` -objects. - - -```{r} -summary(fit) -``` diff --git a/docs/articles/FOCUS_D.html b/docs/articles/FOCUS_D.html index 5da77efa..6607d614 100644 --- a/docs/articles/FOCUS_D.html +++ b/docs/articles/FOCUS_D.html @@ -1,137 +1,103 @@ - - - + - - - - - - - - - - -Example evaluation of FOCUS Example Dataset D - - - - - - - - - - - - - - - - - - - - + + + + +Example evaluation of FOCUS Example Dataset D • mkin + + + + - - - - - - -
- - - - - - - - - - - -