1
0
mirror of https://github.com/msberends/AMR.git synced 2024-12-26 06:06:12 +01:00

(v1.8.1.9009) random when pkg not loaded

This commit is contained in:
dr. M.S. (Matthijs) Berends 2022-05-16 09:29:46 +02:00
parent 58ed15e7ac
commit 2c5bc73ed6
28 changed files with 121 additions and 78 deletions

View File

@ -1,6 +1,6 @@
Package: AMR Package: AMR
Version: 1.8.1.9008 Version: 1.8.1.9009
Date: 2022-05-11 Date: 2022-05-16
Title: Antimicrobial Resistance Data Analysis Title: Antimicrobial Resistance Data Analysis
Description: Functions to simplify and standardise antimicrobial resistance (AMR) Description: Functions to simplify and standardise antimicrobial resistance (AMR)
data analysis and to work with microbial and antimicrobial properties by data analysis and to work with microbial and antimicrobial properties by

View File

@ -1,5 +1,5 @@
# `AMR` 1.8.1.9008 # `AMR` 1.8.1.9009
## <small>Last updated: 11 mei 2022</small> ## <small>Last updated: 16 May 2022</small>
### New ### New
* EUCAST 2022 and CLSI 2022 guidelines have been added for `as.rsi()`. EUCAST 2022 is now the new default guideline for all MIC and disks diffusion interpretations. * EUCAST 2022 and CLSI 2022 guidelines have been added for `as.rsi()`. EUCAST 2022 is now the new default guideline for all MIC and disks diffusion interpretations.
@ -10,6 +10,7 @@
* `droplevels()` on MIC will now return a common `factor` at default and will lose the `<mic>` class. Use `droplevels(..., as.mic = TRUE)` to keep the `<mic>` class. * `droplevels()` on MIC will now return a common `factor` at default and will lose the `<mic>` class. Use `droplevels(..., as.mic = TRUE)` to keep the `<mic>` class.
* Small fix for using `ab_from_text()` * Small fix for using `ab_from_text()`
* Fixes for reading in text files using `set_mo_source()`, which now also allows the source file to contain valid taxonomic names instead of only valid microorganism ID of this package * Fixes for reading in text files using `set_mo_source()`, which now also allows the source file to contain valid taxonomic names instead of only valid microorganism ID of this package
* Using any `random_*()` function (such as `random_mic()`) is now possible by directly calling the package without loading it first: `AMR::random_mic(10)`
# `AMR` 1.8.1 # `AMR` 1.8.1

View File

@ -251,7 +251,14 @@
#' - `breakpoint_S`\cr Lowest MIC value or highest number of millimetres that leads to "S" #' - `breakpoint_S`\cr Lowest MIC value or highest number of millimetres that leads to "S"
#' - `breakpoint_R`\cr Highest MIC value or lowest number of millimetres that leads to "R" #' - `breakpoint_R`\cr Highest MIC value or lowest number of millimetres that leads to "R"
#' - `uti`\cr A [logical] value (`TRUE`/`FALSE`) to indicate whether the rule applies to a urinary tract infection (UTI) #' - `uti`\cr A [logical] value (`TRUE`/`FALSE`) to indicate whether the rule applies to a urinary tract infection (UTI)
#' @details The repository of this `AMR` package contains a file comprising this exact data set: <https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt>. This file **allows for machine reading EUCAST and CLSI guidelines**, which is almost impossible with the Excel and PDF files distributed by EUCAST and CLSI. The file is updated automatically and the `mo` and `ab` columns have been transformed to contain the full official names instead of codes. #' @details
#' Overview of the data set:
#'
#' ```{r}
#' head(rsi_translation)
#' ```
#'
#' The repository of this `AMR` package contains a file comprising this exact data set: <https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt>. This file **allows for machine reading EUCAST and CLSI guidelines**, which is almost impossible with the Excel and PDF files distributed by EUCAST and CLSI. The file is updated automatically and the `mo` and `ab` columns have been transformed to contain the full official names instead of codes.
#' @inheritSection AMR Reference Data Publicly Available #' @inheritSection AMR Reference Data Publicly Available
#' @inheritSection AMR Read more on Our Website! #' @inheritSection AMR Read more on Our Website!
#' @seealso [intrinsic_resistant] #' @seealso [intrinsic_resistant]

View File

@ -34,7 +34,7 @@
#' @param ... ignored, only in place to allow future extensions #' @param ... ignored, only in place to allow future extensions
#' @details The base \R function [sample()] is used for generating values. #' @details The base \R function [sample()] is used for generating values.
#' #'
#' Generated values are based on the latest EUCAST guideline implemented in the [rsi_translation] data set. To create specific generated values per bug or drug, set the `mo` and/or `ab` argument. #' Generated values are based on the EUCAST `r max(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "EUCAST")$guideline)))` guideline as implemented in the [rsi_translation] data set. To create specific generated values per bug or drug, set the `mo` and/or `ab` argument.
#' @return class `<mic>` for [random_mic()] (see [as.mic()]) and class `<disk>` for [random_disk()] (see [as.disk()]) #' @return class `<mic>` for [random_mic()] (see [as.mic()]) and class `<disk>` for [random_disk()] (see [as.disk()])
#' @name random #' @name random
#' @rdname random #' @rdname random
@ -89,6 +89,7 @@ random_rsi <- function(size = NULL, prob_RSI = c(0.33, 0.33, 0.33), ...) {
} }
random_exec <- function(type, size, mo = NULL, ab = NULL) { random_exec <- function(type, size, mo = NULL, ab = NULL) {
check_dataset_integrity()
df <- rsi_translation %pm>% df <- rsi_translation %pm>%
pm_filter(guideline %like% "EUCAST") %pm>% pm_filter(guideline %like% "EUCAST") %pm>%
pm_arrange(pm_desc(guideline)) %pm>% pm_arrange(pm_desc(guideline)) %pm>%

View File

@ -33,7 +33,7 @@
#' @param ab any (vector of) text that can be coerced to a valid antimicrobial code with [as.ab()] #' @param ab any (vector of) text that can be coerced to a valid antimicrobial code with [as.ab()]
#' @param uti (Urinary Tract Infection) A vector with [logical]s (`TRUE` or `FALSE`) to specify whether a UTI specific interpretation from the guideline should be chosen. For using [as.rsi()] on a [data.frame], this can also be a column containing [logical]s or when left blank, the data set will be searched for a column 'specimen', and rows within this column containing 'urin' (such as 'urine', 'urina') will be regarded isolates from a UTI. See *Examples*. #' @param uti (Urinary Tract Infection) A vector with [logical]s (`TRUE` or `FALSE`) to specify whether a UTI specific interpretation from the guideline should be chosen. For using [as.rsi()] on a [data.frame], this can also be a column containing [logical]s or when left blank, the data set will be searched for a column 'specimen', and rows within this column containing 'urin' (such as 'urine', 'urina') will be regarded isolates from a UTI. See *Examples*.
#' @inheritParams first_isolate #' @inheritParams first_isolate
#' @param guideline defaults to the latest included EUCAST guideline, supports EUCAST (`r min(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "EUCAST")$guideline)))`-`r max(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "EUCAST")$guideline)))`) and CLSI (`r min(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "CLSI")$guideline)))`-`r max(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "CLSI")$guideline)))`), see *Details* #' @param guideline defaults to EUCAST `r max(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "EUCAST")$guideline)))` (the latest implemented EUCAST guideline in the [rsi_translation] data set), supports EUCAST (`r min(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "EUCAST")$guideline)))`-`r max(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "EUCAST")$guideline)))`) and CLSI (`r min(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "CLSI")$guideline)))`-`r max(as.integer(gsub("[^0-9]", "", subset(rsi_translation, guideline %like% "CLSI")$guideline)))`), see *Details*
#' @param conserve_capped_values a [logical] to indicate that MIC values starting with `">"` (but not `">="`) must always return "R" , and that MIC values starting with `"<"` (but not `"<="`) must always return "S" #' @param conserve_capped_values a [logical] to indicate that MIC values starting with `">"` (but not `">="`) must always return "R" , and that MIC values starting with `"<"` (but not `"<="`) must always return "S"
#' @param add_intrinsic_resistance *(only useful when using a EUCAST guideline)* a [logical] to indicate whether intrinsic antibiotic resistance must also be considered for applicable bug-drug combinations, meaning that e.g. ampicillin will always return "R" in *Klebsiella* species. Determination is based on the [intrinsic_resistant] data set, that itself is based on `r format_eucast_version_nr(3.3)`. #' @param add_intrinsic_resistance *(only useful when using a EUCAST guideline)* a [logical] to indicate whether intrinsic antibiotic resistance must also be considered for applicable bug-drug combinations, meaning that e.g. ampicillin will always return "R" in *Klebsiella* species. Determination is based on the [intrinsic_resistant] data set, that itself is based on `r format_eucast_version_nr(3.3)`.
#' @param reference_data a [data.frame] to be used for interpretation, which defaults to the [rsi_translation] data set. Changing this argument allows for using own interpretation guidelines. This argument must contain a data set that is equal in structure to the [rsi_translation] data set (same column names and column types). Please note that the `guideline` argument will be ignored when `reference_data` is manually set. #' @param reference_data a [data.frame] to be used for interpretation, which defaults to the [rsi_translation] data set. Changing this argument allows for using own interpretation guidelines. This argument must contain a data set that is equal in structure to the [rsi_translation] data set (same column names and column types). Please note that the `guideline` argument will be ignored when `reference_data` is manually set.

Binary file not shown.

Binary file not shown.

View File

@ -43,7 +43,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="https://msberends.github.io/AMR/index.html">AMR (for R)</a> <a class="navbar-link" href="https://msberends.github.io/AMR/index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9008</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="index.html">AMR (for R)</a> <a class="navbar-link" href="index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9008</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -44,7 +44,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9008</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>
@ -190,7 +190,7 @@
<div class="page-header toc-ignore"> <div class="page-header toc-ignore">
<h1 data-toc-skip>Data sets for download / own use</h1> <h1 data-toc-skip>Data sets for download / own use</h1>
<h4 data-toc-skip class="date">11 mei 2022</h4> <h4 data-toc-skip class="date">16 May 2022</h4>
<small class="dont-index">Source: <a href="https://github.com/msberends/AMR/blob/HEAD/vignettes/datasets.Rmd" class="external-link"><code>vignettes/datasets.Rmd</code></a></small> <small class="dont-index">Source: <a href="https://github.com/msberends/AMR/blob/HEAD/vignettes/datasets.Rmd" class="external-link"><code>vignettes/datasets.Rmd</code></a></small>
<div class="hidden name"><code>datasets.Rmd</code></div> <div class="hidden name"><code>datasets.Rmd</code></div>
@ -224,8 +224,8 @@ column names:<br><em>mo</em>, <em>fullname</em>, <em>kingdom</em>, <em>phylum</e
<em>snomed</em>.</p> <em>snomed</em>.</p>
<p>This data set is in R available as <code>microorganisms</code>, after <p>This data set is in R available as <code>microorganisms</code>, after
you load the <code>AMR</code> package.</p> you load the <code>AMR</code> package.</p>
<p>It was last updated on 9 mei 2022 20:57:33 UTC. Find more info about <p>It was last updated on 29 November 2021 11:38:23 UTC. Find more info
the structure of this data set <a href="https://msberends.github.io/AMR/reference/microorganisms.html">here</a>.</p> about the structure of this data set <a href="https://msberends.github.io/AMR/reference/microorganisms.html">here</a>.</p>
<p><strong>Direct download links:</strong></p> <p><strong>Direct download links:</strong></p>
<ul> <ul>
<li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/microorganisms.rds" class="external-link">R <li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/microorganisms.rds" class="external-link">R
@ -466,8 +466,8 @@ i.e. of column <em>fullname_new</em>, see the
<code>microorganisms</code> data set.</p> <code>microorganisms</code> data set.</p>
<p>This data set is in R available as <code>microorganisms.old</code>, <p>This data set is in R available as <code>microorganisms.old</code>,
after you load the <code>AMR</code> package.</p> after you load the <code>AMR</code> package.</p>
<p>It was last updated on 9 mei 2022 20:57:33 UTC. Find more info about <p>It was last updated on 6 October 2021 14:38:29 UTC. Find more info
the structure of this data set <a href="https://msberends.github.io/AMR/reference/microorganisms.old.html">here</a>.</p> about the structure of this data set <a href="https://msberends.github.io/AMR/reference/microorganisms.old.html">here</a>.</p>
<p><strong>Direct download links:</strong></p> <p><strong>Direct download links:</strong></p>
<ul> <ul>
<li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/microorganisms.old.rds" class="external-link">R <li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/microorganisms.old.rds" class="external-link">R
@ -553,8 +553,8 @@ column names:<br><em>ab</em>, <em>cid</em>, <em>name</em>, <em>group</em>, <em>a
<em>iv_ddd</em>, <em>iv_units</em> and <em>loinc</em>.</p> <em>iv_ddd</em>, <em>iv_units</em> and <em>loinc</em>.</p>
<p>This data set is in R available as <code>antibiotics</code>, after <p>This data set is in R available as <code>antibiotics</code>, after
you load the <code>AMR</code> package.</p> you load the <code>AMR</code> package.</p>
<p>It was last updated on 9 mei 2022 20:57:33 UTC. Find more info about <p>It was last updated on 14 December 2021 21:59:33 UTC. Find more info
the structure of this data set <a href="https://msberends.github.io/AMR/reference/antibiotics.html">here</a>.</p> about the structure of this data set <a href="https://msberends.github.io/AMR/reference/antibiotics.html">here</a>.</p>
<p><strong>Direct download links:</strong></p> <p><strong>Direct download links:</strong></p>
<ul> <ul>
<li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/antibiotics.rds" class="external-link">R <li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/antibiotics.rds" class="external-link">R
@ -740,8 +740,8 @@ column names:<br><em>atc</em>, <em>cid</em>, <em>name</em>, <em>atc_group</em>,
<em>iv_ddd</em> and <em>iv_units</em>.</p> <em>iv_ddd</em> and <em>iv_units</em>.</p>
<p>This data set is in R available as <code>antivirals</code>, after you <p>This data set is in R available as <code>antivirals</code>, after you
load the <code>AMR</code> package.</p> load the <code>AMR</code> package.</p>
<p>It was last updated on 9 mei 2022 20:57:33 UTC. Find more info about <p>It was last updated on 29 August 2020 19:53:07 UTC. Find more info
the structure of this data set <a href="https://msberends.github.io/AMR/reference/antibiotics.html">here</a>.</p> about the structure of this data set <a href="https://msberends.github.io/AMR/reference/antibiotics.html">here</a>.</p>
<p><strong>Direct download links:</strong></p> <p><strong>Direct download links:</strong></p>
<ul> <ul>
<li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/antivirals.rds" class="external-link">R <li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/antivirals.rds" class="external-link">R
@ -883,13 +883,13 @@ Dipivoxil, …</td>
<div class="section level2"> <div class="section level2">
<h2 id="interpretation-from-mic-values-disk-diameters-to-rsi">Interpretation from MIC values / disk diameters to R/SI<a class="anchor" aria-label="anchor" href="#interpretation-from-mic-values-disk-diameters-to-rsi"></a> <h2 id="interpretation-from-mic-values-disk-diameters-to-rsi">Interpretation from MIC values / disk diameters to R/SI<a class="anchor" aria-label="anchor" href="#interpretation-from-mic-values-disk-diameters-to-rsi"></a>
</h2> </h2>
<p>A data set with 20,369 rows and 11 columns, containing the following <p>A data set with 20,318 rows and 11 columns, containing the following
column names:<br><em>guideline</em>, <em>method</em>, <em>site</em>, <em>mo</em>, column names:<br><em>guideline</em>, <em>method</em>, <em>site</em>, <em>mo</em>,
<em>rank_index</em>, <em>ab</em>, <em>ref_tbl</em>, <em>disk_dose</em>, <em>rank_index</em>, <em>ab</em>, <em>ref_tbl</em>, <em>disk_dose</em>,
<em>breakpoint_S</em>, <em>breakpoint_R</em> and <em>uti</em>.</p> <em>breakpoint_S</em>, <em>breakpoint_R</em> and <em>uti</em>.</p>
<p>This data set is in R available as <code>rsi_translation</code>, <p>This data set is in R available as <code>rsi_translation</code>,
after you load the <code>AMR</code> package.</p> after you load the <code>AMR</code> package.</p>
<p>It was last updated on 11 mei 2022 08:14:33 UTC. Find more info about <p>It was last updated on 10 May 2022 19:42:39 UTC. Find more info about
the structure of this data set <a href="https://msberends.github.io/AMR/reference/rsi_translation.html">here</a>.</p> the structure of this data set <a href="https://msberends.github.io/AMR/reference/rsi_translation.html">here</a>.</p>
<p><strong>Direct download links:</strong></p> <p><strong>Direct download links:</strong></p>
<ul> <ul>
@ -915,8 +915,8 @@ file</a> (3.8 MB)</li>
<h3 id="source-4">Source<a class="anchor" aria-label="anchor" href="#source-4"></a> <h3 id="source-4">Source<a class="anchor" aria-label="anchor" href="#source-4"></a>
</h3> </h3>
<p>This data set contains interpretation rules for MIC values and disk <p>This data set contains interpretation rules for MIC values and disk
diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST diffusion diameters. Included guidelines are CLSI (2010-2021) and EUCAST
(2011-2022).</p> (2011-2021).</p>
</div> </div>
<div class="section level3"> <div class="section level3">
<h3 id="example-content-4">Example content<a class="anchor" aria-label="anchor" href="#example-content-4"></a> <h3 id="example-content-4">Example content<a class="anchor" aria-label="anchor" href="#example-content-4"></a>
@ -954,7 +954,7 @@ diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST
</tr></thead> </tr></thead>
<tbody> <tbody>
<tr class="odd"> <tr class="odd">
<td align="center">EUCAST 2022</td> <td align="center">EUCAST 2021</td>
<td align="center">MIC</td> <td align="center">MIC</td>
<td align="center"></td> <td align="center"></td>
<td align="center">F_ASPRG_MGTS</td> <td align="center">F_ASPRG_MGTS</td>
@ -965,11 +965,11 @@ diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST
<td align="center">Aspergillus</td> <td align="center">Aspergillus</td>
<td align="center"></td> <td align="center"></td>
<td align="center">1</td> <td align="center">1</td>
<td align="center">1</td> <td align="center">4</td>
<td align="center">FALSE</td> <td align="center">FALSE</td>
</tr> </tr>
<tr class="even"> <tr class="even">
<td align="center">EUCAST 2022</td> <td align="center">EUCAST 2021</td>
<td align="center">MIC</td> <td align="center">MIC</td>
<td align="center"></td> <td align="center"></td>
<td align="center">F_ASPRG_NIGR</td> <td align="center">F_ASPRG_NIGR</td>
@ -980,11 +980,11 @@ diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST
<td align="center">Aspergillus</td> <td align="center">Aspergillus</td>
<td align="center"></td> <td align="center"></td>
<td align="center">1</td> <td align="center">1</td>
<td align="center">1</td> <td align="center">4</td>
<td align="center">FALSE</td> <td align="center">FALSE</td>
</tr> </tr>
<tr class="odd"> <tr class="odd">
<td align="center">EUCAST 2022</td> <td align="center">EUCAST 2021</td>
<td align="center">MIC</td> <td align="center">MIC</td>
<td align="center"></td> <td align="center"></td>
<td align="center">F_CANDD</td> <td align="center">F_CANDD</td>
@ -995,11 +995,11 @@ diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST
<td align="center">Candida</td> <td align="center">Candida</td>
<td align="center"></td> <td align="center"></td>
<td align="center">1</td> <td align="center">1</td>
<td align="center">1</td> <td align="center">2</td>
<td align="center">FALSE</td> <td align="center">FALSE</td>
</tr> </tr>
<tr class="even"> <tr class="even">
<td align="center">EUCAST 2022</td> <td align="center">EUCAST 2021</td>
<td align="center">MIC</td> <td align="center">MIC</td>
<td align="center"></td> <td align="center"></td>
<td align="center">F_CANDD_ALBC</td> <td align="center">F_CANDD_ALBC</td>
@ -1010,26 +1010,11 @@ diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST
<td align="center">Candida</td> <td align="center">Candida</td>
<td align="center"></td> <td align="center"></td>
<td align="center">1</td> <td align="center">1</td>
<td align="center">1</td> <td align="center">2</td>
<td align="center">FALSE</td> <td align="center">FALSE</td>
</tr> </tr>
<tr class="odd"> <tr class="odd">
<td align="center">EUCAST 2022</td> <td align="center">EUCAST 2021</td>
<td align="center">MIC</td>
<td align="center"></td>
<td align="center">F_CANDD_DBLN</td>
<td align="center">Candida dubliniensis</td>
<td align="center">2</td>
<td align="center">AMB</td>
<td align="center">Amphotericin B</td>
<td align="center">Candida</td>
<td align="center"></td>
<td align="center">1</td>
<td align="center">1</td>
<td align="center">FALSE</td>
</tr>
<tr class="even">
<td align="center">EUCAST 2022</td>
<td align="center">MIC</td> <td align="center">MIC</td>
<td align="center"></td> <td align="center"></td>
<td align="center">F_CANDD_KRUS</td> <td align="center">F_CANDD_KRUS</td>
@ -1040,7 +1025,22 @@ diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST
<td align="center">Candida</td> <td align="center">Candida</td>
<td align="center"></td> <td align="center"></td>
<td align="center">1</td> <td align="center">1</td>
<td align="center">2</td>
<td align="center">FALSE</td>
</tr>
<tr class="even">
<td align="center">EUCAST 2021</td>
<td align="center">MIC</td>
<td align="center"></td>
<td align="center">F_CANDD_PRPS</td>
<td align="center">Candida parapsilosis</td>
<td align="center">2</td>
<td align="center">AMB</td>
<td align="center">Amphotericin B</td>
<td align="center">Candida</td>
<td align="center"></td>
<td align="center">1</td> <td align="center">1</td>
<td align="center">2</td>
<td align="center">FALSE</td> <td align="center">FALSE</td>
</tr> </tr>
</tbody> </tbody>
@ -1054,8 +1054,8 @@ diffusion diameters. Included guidelines are CLSI (2011-2022) and EUCAST
column names:<br><em>mo</em> and <em>ab</em>.</p> column names:<br><em>mo</em> and <em>ab</em>.</p>
<p>This data set is in R available as <code>intrinsic_resistant</code>, <p>This data set is in R available as <code>intrinsic_resistant</code>,
after you load the <code>AMR</code> package.</p> after you load the <code>AMR</code> package.</p>
<p>It was last updated on 9 mei 2022 20:57:33 UTC. Find more info about <p>It was last updated on 14 December 2021 21:59:33 UTC. Find more info
the structure of this data set <a href="https://msberends.github.io/AMR/reference/intrinsic_resistant.html">here</a>.</p> about the structure of this data set <a href="https://msberends.github.io/AMR/reference/intrinsic_resistant.html">here</a>.</p>
<p><strong>Direct download links:</strong></p> <p><strong>Direct download links:</strong></p>
<ul> <ul>
<li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/intrinsic_resistant.rds" class="external-link">R <li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/intrinsic_resistant.rds" class="external-link">R
@ -1335,8 +1335,8 @@ column names:<br><em>ab</em>, <em>name</em>, <em>type</em>, <em>dose</em>,
<em>original_txt</em> and <em>eucast_version</em>.</p> <em>original_txt</em> and <em>eucast_version</em>.</p>
<p>This data set is in R available as <code>dosage</code>, after you <p>This data set is in R available as <code>dosage</code>, after you
load the <code>AMR</code> package.</p> load the <code>AMR</code> package.</p>
<p>It was last updated on 9 mei 2022 20:57:33 UTC. Find more info about <p>It was last updated on 25 January 2021 20:58:20 UTC. Find more info
the structure of this data set <a href="https://msberends.github.io/AMR/reference/dosage.html">here</a>.</p> about the structure of this data set <a href="https://msberends.github.io/AMR/reference/dosage.html">here</a>.</p>
<p><strong>Direct download links:</strong></p> <p><strong>Direct download links:</strong></p>
<ul> <ul>
<li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/dosage.rds" class="external-link">R <li>Download as <a href="https://github.com/msberends/AMR/raw/main/data-raw/../data-raw/dosage.rds" class="external-link">R

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="index.html">AMR (for R)</a> <a class="navbar-link" href="index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9008</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -47,7 +47,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="index.html">AMR (for R)</a> <a class="navbar-link" href="index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9008</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9008</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>
@ -157,16 +157,16 @@
</div> </div>
<div class="section level2"> <div class="section level2">
<h2 class="page-header" data-toc-text="1.8.1.9008" id="amr-1819008"> <h2 class="page-header" data-toc-text="1.8.1.9009" id="amr-1819009">
<code>AMR</code> 1.8.1.9008<a class="anchor" aria-label="anchor" href="#amr-1819008"></a></h2> <code>AMR</code> 1.8.1.9009<a class="anchor" aria-label="anchor" href="#amr-1819009"></a></h2>
<div class="section level3"> <div class="section level3">
<h3 id="last-updated-mei-1-8-1-9008"><small>Last updated: 11 mei 2022</small><a class="anchor" aria-label="anchor" href="#last-updated-mei-1-8-1-9008"></a></h3> <h3 id="last-updated-may-1-8-1-9009"><small>Last updated: 16 May 2022</small><a class="anchor" aria-label="anchor" href="#last-updated-may-1-8-1-9009"></a></h3>
<div class="section level4"> <div class="section level4">
<h4 id="new-1-8-1-9008">New<a class="anchor" aria-label="anchor" href="#new-1-8-1-9008"></a></h4> <h4 id="new-1-8-1-9009">New<a class="anchor" aria-label="anchor" href="#new-1-8-1-9009"></a></h4>
<ul><li>EUCAST 2022 and CLSI 2022 guidelines have been added for <code><a href="../reference/as.rsi.html">as.rsi()</a></code>. EUCAST 2022 is now the new default guideline for all MIC and disks diffusion interpretations.</li> <ul><li>EUCAST 2022 and CLSI 2022 guidelines have been added for <code><a href="../reference/as.rsi.html">as.rsi()</a></code>. EUCAST 2022 is now the new default guideline for all MIC and disks diffusion interpretations.</li>
</ul></div> </ul></div>
<div class="section level4"> <div class="section level4">
<h4 id="changed-1-8-1-9008">Changed<a class="anchor" aria-label="anchor" href="#changed-1-8-1-9008"></a></h4> <h4 id="changed-1-8-1-9009">Changed<a class="anchor" aria-label="anchor" href="#changed-1-8-1-9009"></a></h4>
<ul><li>Fix for <code><a href="../reference/as.rsi.html">as.rsi()</a></code> on certain EUCAST breakpoints for MIC values</li> <ul><li>Fix for <code><a href="../reference/as.rsi.html">as.rsi()</a></code> on certain EUCAST breakpoints for MIC values</li>
<li>Removed <code><a href="https://rdrr.io/r/base/integer.html" class="external-link">as.integer()</a></code> for MIC values, since MIC are not integer values and running <code><a href="https://rdrr.io/r/base/table.html" class="external-link">table()</a></code> on MIC values consequently failed for not being able to retrieve the level position (as thats how normally <code><a href="https://rdrr.io/r/base/integer.html" class="external-link">as.integer()</a></code> on <code>factor</code>s work)</li> <li>Removed <code><a href="https://rdrr.io/r/base/integer.html" class="external-link">as.integer()</a></code> for MIC values, since MIC are not integer values and running <code><a href="https://rdrr.io/r/base/table.html" class="external-link">table()</a></code> on MIC values consequently failed for not being able to retrieve the level position (as thats how normally <code><a href="https://rdrr.io/r/base/integer.html" class="external-link">as.integer()</a></code> on <code>factor</code>s work)</li>
<li> <li>
@ -174,6 +174,8 @@
<li>Small fix for using <code><a href="../reference/ab_from_text.html">ab_from_text()</a></code> <li>Small fix for using <code><a href="../reference/ab_from_text.html">ab_from_text()</a></code>
</li> </li>
<li>Fixes for reading in text files using <code><a href="../reference/mo_source.html">set_mo_source()</a></code>, which now also allows the source file to contain valid taxonomic names instead of only valid microorganism ID of this package</li> <li>Fixes for reading in text files using <code><a href="../reference/mo_source.html">set_mo_source()</a></code>, which now also allows the source file to contain valid taxonomic names instead of only valid microorganism ID of this package</li>
<li>Using any <code>random_*()</code> function (such as <code><a href="../reference/random.html">random_mic()</a></code>) is now possible by directly calling the package without loading it first: <code>AMR::random_mic(10)</code>
</li>
</ul></div> </ul></div>
</div> </div>
</div> </div>
@ -1693,7 +1695,7 @@ This works for all drug combinations, such as ampicillin/sulbactam, ceftazidime/
<div class="sourceCode" id="cb49"><pre class="downlit sourceCode r"> <div class="sourceCode" id="cb49"><pre class="downlit sourceCode r">
<code class="sourceCode R"> <code class="sourceCode R">
<span class="va">thousands_of_E_colis</span> <span class="op">&lt;-</span> <span class="fu"><a href="https://rdrr.io/r/base/rep.html" class="external-link">rep</a></span><span class="op">(</span><span class="st">"E. coli"</span>, <span class="fl">25000</span><span class="op">)</span> <span class="va">thousands_of_E_colis</span> <span class="op">&lt;-</span> <span class="fu"><a href="https://rdrr.io/r/base/rep.html" class="external-link">rep</a></span><span class="op">(</span><span class="st">"E. coli"</span>, <span class="fl">25000</span><span class="op">)</span>
<span class="fu">microbenchmark</span><span class="fu">::</span><span class="fu">microbenchmark</span><span class="op">(</span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="va">thousands_of_E_colis</span><span class="op">)</span>, unit <span class="op">=</span> <span class="st">"s"</span><span class="op">)</span> <span class="fu">microbenchmark</span><span class="fu">::</span><span class="fu"><a href="https://rdrr.io/pkg/microbenchmark/man/microbenchmark.html" class="external-link">microbenchmark</a></span><span class="op">(</span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="va">thousands_of_E_colis</span><span class="op">)</span>, unit <span class="op">=</span> <span class="st">"s"</span><span class="op">)</span>
<span class="co"># Unit: seconds</span> <span class="co"># Unit: seconds</span>
<span class="co"># min median max neval</span> <span class="co"># min median max neval</span>
<span class="co"># 0.01817717 0.01843957 0.03878077 100</span></code></pre></div> <span class="co"># 0.01817717 0.01843957 0.03878077 100</span></code></pre></div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9002</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9007</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>
@ -225,7 +225,7 @@
<dt>ab</dt> <dt>ab</dt>
<dd><p>any (vector of) text that can be coerced to a valid antimicrobial code with <code><a href="as.ab.html">as.ab()</a></code></p></dd> <dd><p>any (vector of) text that can be coerced to a valid antimicrobial code with <code><a href="as.ab.html">as.ab()</a></code></p></dd>
<dt>guideline</dt> <dt>guideline</dt>
<dd><p>defaults to the latest included EUCAST guideline, supports EUCAST (2011-2022) and CLSI (2011-2022), see <em>Details</em></p></dd> <dd><p>defaults to EUCAST 2022 (the latest implemented EUCAST guideline in the <a href="rsi_translation.html">rsi_translation</a> data set), supports EUCAST (2011-2022) and CLSI (2011-2022), see <em>Details</em></p></dd>
<dt>uti</dt> <dt>uti</dt>
<dd><p>(Urinary Tract Infection) A vector with <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a>s (<code>TRUE</code> or <code>FALSE</code>) to specify whether a UTI specific interpretation from the guideline should be chosen. For using <code>as.rsi()</code> on a <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a>, this can also be a column containing <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a>s or when left blank, the data set will be searched for a column 'specimen', and rows within this column containing 'urin' (such as 'urine', 'urina') will be regarded isolates from a UTI. See <em>Examples</em>.</p></dd> <dd><p>(Urinary Tract Infection) A vector with <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a>s (<code>TRUE</code> or <code>FALSE</code>) to specify whether a UTI specific interpretation from the guideline should be chosen. For using <code>as.rsi()</code> on a <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a>, this can also be a column containing <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a>s or when left blank, the data set will be searched for a column 'specimen', and rows within this column containing 'urin' (such as 'urine', 'urina') will be regarded isolates from a UTI. See <em>Examples</em>.</p></dd>
<dt>conserve_capped_values</dt> <dt>conserve_capped_values</dt>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9007</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>
@ -180,7 +180,7 @@
<dd><p>a numeric vector; ignored if <code>x</code> is a matrix. If <dd><p>a numeric vector; ignored if <code>x</code> is a matrix. If
<code>x</code> is a factor, <code>y</code> should be a factor of the same length.</p></dd> <code>x</code> is a factor, <code>y</code> should be a factor of the same length.</p></dd>
<dt>p</dt> <dt>p</dt>
<dd><p>a vector of probabilities of the same length of <code>x</code>. <dd><p>a vector of probabilities of the same length as <code>x</code>.
An error is given if any entry of <code>p</code> is negative.</p></dd> An error is given if any entry of <code>p</code> is negative.</p></dd>
<dt>rescale.p</dt> <dt>rescale.p</dt>
<dd><p>a logical scalar; if TRUE then <code>p</code> is rescaled <dd><p>a logical scalar; if TRUE then <code>p</code> is rescaled

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9007</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9002</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9002</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9002</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -18,7 +18,7 @@ This is the fastest way to have your organisation (or analysis) specific codes p
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9003</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9007</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>
@ -189,7 +189,7 @@
<div id="details"> <div id="details">
<h2>Details</h2> <h2>Details</h2>
<p>The base <span style="R">R</span> function <code><a href="https://rdrr.io/r/base/sample.html" class="external-link">sample()</a></code> is used for generating values.</p> <p>The base <span style="R">R</span> function <code><a href="https://rdrr.io/r/base/sample.html" class="external-link">sample()</a></code> is used for generating values.</p>
<p>Generated values are based on the latest EUCAST guideline implemented in the <a href="rsi_translation.html">rsi_translation</a> data set. To create specific generated values per bug or drug, set the <code>mo</code> and/or <code>ab</code> argument.</p> <p>Generated values are based on the EUCAST 2022 guideline as implemented in the <a href="rsi_translation.html">rsi_translation</a> data set. To create specific generated values per bug or drug, set the <code>mo</code> and/or <code>ab</code> argument.</p>
</div> </div>
<div id="stable-lifecycle"> <div id="stable-lifecycle">
<h2>Stable Lifecycle</h2> <h2>Stable Lifecycle</h2>

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="../index.html">AMR (for R)</a> <a class="navbar-link" href="../index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9007</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>
@ -181,6 +181,21 @@
</ul></div> </ul></div>
<div id="details"> <div id="details">
<h2>Details</h2> <h2>Details</h2>
<p>Overview of the data set:</p><div class="sourceCode r"><pre><code><span class="fu"><a href="https://rdrr.io/r/utils/head.html" class="external-link">head</a></span><span class="op">(</span><span class="va">rsi_translation</span><span class="op">)</span></code></pre><p></p></div><div class="sourceCode"><pre><code><span class="co">## guideline method site mo rank_index ab ref_tbl disk_dose</span>
<span class="co">## 1 EUCAST 2022 MIC &lt;NA&gt; F_ASPRG_MGTS 2 AMB Aspergillus &lt;NA&gt;</span>
<span class="co">## 2 EUCAST 2022 MIC &lt;NA&gt; F_ASPRG_NIGR 2 AMB Aspergillus &lt;NA&gt;</span>
<span class="co">## 3 EUCAST 2022 MIC &lt;NA&gt; F_CANDD 3 AMB Candida &lt;NA&gt;</span>
<span class="co">## 4 EUCAST 2022 MIC &lt;NA&gt; F_CANDD_ALBC 2 AMB Candida &lt;NA&gt;</span>
<span class="co">## 5 EUCAST 2022 MIC &lt;NA&gt; F_CANDD_DBLN 2 AMB Candida &lt;NA&gt;</span>
<span class="co">## 6 EUCAST 2022 MIC &lt;NA&gt; F_CANDD_KRUS 2 AMB Candida &lt;NA&gt;</span>
<span class="co">## breakpoint_S breakpoint_R uti</span>
<span class="co">## 1 1 1 FALSE</span>
<span class="co">## 2 1 1 FALSE</span>
<span class="co">## 3 1 1 FALSE</span>
<span class="co">## 4 1 1 FALSE</span>
<span class="co">## 5 1 1 FALSE</span>
<span class="co">## 6 1 1 FALSE</span></code></pre></div>
<p>The repository of this <code>AMR</code> package contains a file comprising this exact data set: <a href="https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt" class="external-link">https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt</a>. This file <strong>allows for machine reading EUCAST and CLSI guidelines</strong>, which is almost impossible with the Excel and PDF files distributed by EUCAST and CLSI. The file is updated automatically and the <code>mo</code> and <code>ab</code> columns have been transformed to contain the full official names instead of codes.</p> <p>The repository of this <code>AMR</code> package contains a file comprising this exact data set: <a href="https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt" class="external-link">https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt</a>. This file <strong>allows for machine reading EUCAST and CLSI guidelines</strong>, which is almost impossible with the Excel and PDF files distributed by EUCAST and CLSI. The file is updated automatically and the <code>mo</code> and <code>ab</code> columns have been transformed to contain the full official names instead of codes.</p>
</div> </div>
<div id="reference-data-publicly-available"> <div id="reference-data-publicly-available">

View File

@ -17,7 +17,7 @@
</button> </button>
<span class="navbar-brand"> <span class="navbar-brand">
<a class="navbar-link" href="index.html">AMR (for R)</a> <a class="navbar-link" href="index.html">AMR (for R)</a>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9008</span> <span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.8.1.9009</span>
</span> </span>
</div> </div>

View File

@ -68,7 +68,7 @@ is.rsi.eligible(x, threshold = 0.05)
\item{ab}{any (vector of) text that can be coerced to a valid antimicrobial code with \code{\link[=as.ab]{as.ab()}}} \item{ab}{any (vector of) text that can be coerced to a valid antimicrobial code with \code{\link[=as.ab]{as.ab()}}}
\item{guideline}{defaults to the latest included EUCAST guideline, supports EUCAST (2011-2022) and CLSI (2011-2022), see \emph{Details}} \item{guideline}{defaults to EUCAST 2022 (the latest implemented EUCAST guideline in the \link{rsi_translation} data set), supports EUCAST (2011-2022) and CLSI (2011-2022), see \emph{Details}}
\item{uti}{(Urinary Tract Infection) A vector with \link{logical}s (\code{TRUE} or \code{FALSE}) to specify whether a UTI specific interpretation from the guideline should be chosen. For using \code{\link[=as.rsi]{as.rsi()}} on a \link{data.frame}, this can also be a column containing \link{logical}s or when left blank, the data set will be searched for a column 'specimen', and rows within this column containing 'urin' (such as 'urine', 'urina') will be regarded isolates from a UTI. See \emph{Examples}.} \item{uti}{(Urinary Tract Infection) A vector with \link{logical}s (\code{TRUE} or \code{FALSE}) to specify whether a UTI specific interpretation from the guideline should be chosen. For using \code{\link[=as.rsi]{as.rsi()}} on a \link{data.frame}, this can also be a column containing \link{logical}s or when left blank, the data set will be searched for a column 'specimen', and rows within this column containing 'urin' (such as 'urine', 'urina') will be regarded isolates from a UTI. See \emph{Examples}.}

View File

@ -21,7 +21,7 @@ g.test(x, y = NULL, p = rep(1/length(x), length(x)), rescale.p = FALSE)
\item{y}{a numeric vector; ignored if \code{x} is a matrix. If \item{y}{a numeric vector; ignored if \code{x} is a matrix. If
\code{x} is a factor, \code{y} should be a factor of the same length.} \code{x} is a factor, \code{y} should be a factor of the same length.}
\item{p}{a vector of probabilities of the same length of \code{x}. \item{p}{a vector of probabilities of the same length as \code{x}.
An error is given if any entry of \code{p} is negative.} An error is given if any entry of \code{p} is negative.}
\item{rescale.p}{a logical scalar; if TRUE then \code{p} is rescaled \item{rescale.p}{a logical scalar; if TRUE then \code{p} is rescaled

View File

@ -33,7 +33,7 @@ These functions can be used for generating random MIC values and disk diffusion
\details{ \details{
The base \R function \code{\link[=sample]{sample()}} is used for generating values. The base \R function \code{\link[=sample]{sample()}} is used for generating values.
Generated values are based on the latest EUCAST guideline implemented in the \link{rsi_translation} data set. To create specific generated values per bug or drug, set the \code{mo} and/or \code{ab} argument. Generated values are based on the EUCAST 2022 guideline as implemented in the \link{rsi_translation} data set. To create specific generated values per bug or drug, set the \code{mo} and/or \code{ab} argument.
} }
\section{Stable Lifecycle}{ \section{Stable Lifecycle}{

View File

@ -27,6 +27,23 @@ rsi_translation
Data set containing reference data to interpret MIC and disk diffusion to R/SI values, according to international guidelines. Currently implemented guidelines are EUCAST (2011-2022) and CLSI (2011-2022). Use \code{\link[=as.rsi]{as.rsi()}} to transform MICs or disks measurements to R/SI values. Data set containing reference data to interpret MIC and disk diffusion to R/SI values, according to international guidelines. Currently implemented guidelines are EUCAST (2011-2022) and CLSI (2011-2022). Use \code{\link[=as.rsi]{as.rsi()}} to transform MICs or disks measurements to R/SI values.
} }
\details{ \details{
Overview of the data set:\if{html}{\out{<div class="sourceCode r">}}\preformatted{head(rsi_translation)
}\if{html}{\out{</div>}}\preformatted{## guideline method site mo rank_index ab ref_tbl disk_dose
## 1 EUCAST 2022 MIC <NA> F_ASPRG_MGTS 2 AMB Aspergillus <NA>
## 2 EUCAST 2022 MIC <NA> F_ASPRG_NIGR 2 AMB Aspergillus <NA>
## 3 EUCAST 2022 MIC <NA> F_CANDD 3 AMB Candida <NA>
## 4 EUCAST 2022 MIC <NA> F_CANDD_ALBC 2 AMB Candida <NA>
## 5 EUCAST 2022 MIC <NA> F_CANDD_DBLN 2 AMB Candida <NA>
## 6 EUCAST 2022 MIC <NA> F_CANDD_KRUS 2 AMB Candida <NA>
## breakpoint_S breakpoint_R uti
## 1 1 1 FALSE
## 2 1 1 FALSE
## 3 1 1 FALSE
## 4 1 1 FALSE
## 5 1 1 FALSE
## 6 1 1 FALSE
}
The repository of this \code{AMR} package contains a file comprising this exact data set: \url{https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt}. This file \strong{allows for machine reading EUCAST and CLSI guidelines}, which is almost impossible with the Excel and PDF files distributed by EUCAST and CLSI. The file is updated automatically and the \code{mo} and \code{ab} columns have been transformed to contain the full official names instead of codes. The repository of this \code{AMR} package contains a file comprising this exact data set: \url{https://github.com/msberends/AMR/blob/main/data-raw/rsi_translation.txt}. This file \strong{allows for machine reading EUCAST and CLSI guidelines}, which is almost impossible with the Excel and PDF files distributed by EUCAST and CLSI. The file is updated automatically and the \code{mo} and \code{ab} columns have been transformed to contain the full official names instead of codes.
} }
\section{Reference Data Publicly Available}{ \section{Reference Data Publicly Available}{