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

(v1.7.1.9061) bugfix set_ab_names

This commit is contained in:
dr. M.S. (Matthijs) Berends 2021-12-05 23:21:59 +01:00
parent 75965124ef
commit 1fa3fc6af2
10 changed files with 17 additions and 17 deletions

View File

@ -1,5 +1,5 @@
Package: AMR
Version: 1.7.1.9060
Version: 1.7.1.9061
Date: 2021-12-05
Title: Antimicrobial Resistance Data Analysis
Description: Functions to simplify and standardise antimicrobial resistance (AMR)

View File

@ -1,4 +1,4 @@
# `AMR` 1.7.1.9060
# `AMR` 1.7.1.9061
## <small>Last updated: 5 December 2021</small>
### Breaking changes

View File

@ -109,7 +109,7 @@
#'
#' # set_ab_names() works with any AB property:
#' example_isolates %>%
#' set_ab_names("atc")
#' set_ab_names(property = "atc")
#'
#' example_isolates %>%
#' set_ab_names(where(is.rsi)) %>%

Binary file not shown.

View File

@ -44,7 +44,7 @@
</button>
<span class="navbar-brand">
<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.7.1.9060</span>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.7.1.9061</span>
</span>
</div>

View File

@ -17,7 +17,7 @@
</button>
<span class="navbar-brand">
<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.7.1.9060</span>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.7.1.9061</span>
</span>
</div>
@ -157,19 +157,19 @@
</div>
<div class="section level2">
<h2 class="page-header" data-toc-text="1.7.1.9060" id="amr-1719060">
<code>AMR</code> 1.7.1.9060<a class="anchor" aria-label="anchor" href="#amr-1719060"></a></h2>
<h2 class="page-header" data-toc-text="1.7.1.9061" id="amr-1719061">
<code>AMR</code> 1.7.1.9061<a class="anchor" aria-label="anchor" href="#amr-1719061"></a></h2>
<div class="section level3">
<h3 id="last-updated-december-1-7-1-9060"><small>Last updated: 5 December 2021</small><a class="anchor" aria-label="anchor" href="#last-updated-december-1-7-1-9060"></a></h3>
<h3 id="last-updated-december-1-7-1-9061"><small>Last updated: 5 December 2021</small><a class="anchor" aria-label="anchor" href="#last-updated-december-1-7-1-9061"></a></h3>
<div class="section level4">
<h4 id="breaking-changes-1-7-1-9060">Breaking changes<a class="anchor" aria-label="anchor" href="#breaking-changes-1-7-1-9060"></a></h4>
<h4 id="breaking-changes-1-7-1-9061">Breaking changes<a class="anchor" aria-label="anchor" href="#breaking-changes-1-7-1-9061"></a></h4>
<ul><li>Removed <code>p_symbol()</code> and all <code>filter_*()</code> functions (except for <code><a href="../reference/first_isolate.html">filter_first_isolate()</a></code>), which were all deprecated in a previous package version</li>
<li>Removed the <code>key_antibiotics()</code> and <code>key_antibiotics_equal()</code> functions, which were deprecated and superseded by <code><a href="../reference/key_antimicrobials.html">key_antimicrobials()</a></code> and <code><a href="../reference/key_antimicrobials.html">antimicrobials_equal()</a></code>
</li>
<li>Removed all previously implemented <code><a href="https://ggplot2.tidyverse.org/reference/ggplot.html" class="external-link">ggplot2::ggplot()</a></code> generics for classes <code>&lt;mic&gt;</code>, <code>&lt;disk&gt;</code>, <code>&lt;rsi&gt;</code> and <code>&lt;resistance_predict&gt;</code> as they did not follow the <code>ggplot2</code> logic. They were replaced with <code><a href="https://ggplot2.tidyverse.org/reference/autoplot.html" class="external-link">ggplot2::autoplot()</a></code> generics.</li>
</ul></div>
<div class="section level4">
<h4 id="new-1-7-1-9060">New<a class="anchor" aria-label="anchor" href="#new-1-7-1-9060"></a></h4>
<h4 id="new-1-7-1-9061">New<a class="anchor" aria-label="anchor" href="#new-1-7-1-9061"></a></h4>
<ul><li><p>Support for EUCAST Intrinsic Resistance and Unusual Phenotypes v3.3 (October 2021), effective in the <code><a href="../reference/eucast_rules.html">eucast_rules()</a></code> function. This is now the default guideline (all other guidelines are still available).</p></li>
<li>
<p>Function <code><a href="../reference/ab_property.html">set_ab_names()</a></code> to rename data set columns that resemble antimicrobial drugs. This allows for quickly renaming columns to official names, ATC codes, etc. Its second argument can be a tidyverse way of selecting:</p>
@ -181,7 +181,7 @@
<li><p>Support for Danish, and also added missing translations of all antimicrobial drugs in Italian, French and Portuguese</p></li>
</ul></div>
<div class="section level4">
<h4 id="changed-1-7-1-9060">Changed<a class="anchor" aria-label="anchor" href="#changed-1-7-1-9060"></a></h4>
<h4 id="changed-1-7-1-9061">Changed<a class="anchor" aria-label="anchor" href="#changed-1-7-1-9061"></a></h4>
<ul><li>Updated the bacterial taxonomy to 5 October 2021 (according to <a href="https://lpsn.dsmz.de" class="external-link">LPSN</a>), including all 11 new staphylococcal species named since 1 January last year</li>
<li>The <code>antibiotics</code> data set now contains <strong>all ATC codes</strong> that are available through the <a href="https://www.whocc.no" class="external-link">WHOCC website</a>, regardless of drugs being present in more than one ATC group. This means that:
<ul><li>Some drugs now contain multiple ATC codes (e.g., metronidazole contains 5)</li>
@ -247,7 +247,7 @@
<code><a href="../reference/get_episode.html">get_episode()</a></code> and <code><a href="../reference/get_episode.html">is_new_episode()</a></code> can now cope with <code>NA</code>s</li>
</ul></div>
<div class="section level4">
<h4 id="other-1-7-1-9060">Other<a class="anchor" aria-label="anchor" href="#other-1-7-1-9060"></a></h4>
<h4 id="other-1-7-1-9061">Other<a class="anchor" aria-label="anchor" href="#other-1-7-1-9061"></a></h4>
<ul><li>This package is now being maintained by two epidemiologists and a data scientist from two different non-profit healthcare organisations. All functions in this package are now all considered to be stable. Updates to the AMR interpretation rules (such as by EUCAST and CLSI), the microbial taxonomy, and the antibiotic dosages will all be updated every 6 to 12 months from now on.</li>
</ul></div>
</div>

View File

@ -17,7 +17,7 @@
</button>
<span class="navbar-brand">
<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.7.1.9058</span>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.7.1.9061</span>
</span>
</div>
@ -322,7 +322,7 @@ The <a href="lifecycle.html">lifecycle</a> of this function is <strong>stable</s
<span class="co"># set_ab_names() works with any AB property:</span>
<span class="va">example_isolates</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span>
<span class="fu">set_ab_names</span><span class="op">(</span><span class="st">"atc"</span><span class="op">)</span>
<span class="fu">set_ab_names</span><span class="op">(</span>property <span class="op">=</span> <span class="st">"atc"</span><span class="op">)</span>
<span class="va">example_isolates</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span>
<span class="fu">set_ab_names</span><span class="op">(</span><span class="fu">where</span><span class="op">(</span><span class="va">is.rsi</span><span class="op">)</span><span class="op">)</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span>

View File

@ -17,7 +17,7 @@
</button>
<span class="navbar-brand">
<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.7.1.9058</span>
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">1.7.1.9061</span>
</span>
</div>

View File

@ -67,7 +67,7 @@ expect_identical(colnames(set_ab_names(example_isolates[, 20:25])),
c("cefoxitin", "cefotaxime", "ceftazidime", "ceftriaxone", "gentamicin", "tobramycin"))
expect_identical(colnames(set_ab_names(example_isolates[, 20:25], language = "nl", snake_case = FALSE)),
c("Cefoxitine", "Cefotaxim", "Ceftazidim", "Ceftriaxon", "Gentamicine", "Tobramycine"))
expect_identical(colnames(set_ab_names(example_isolates[, 20:25], "atc")),
expect_identical(colnames(set_ab_names(example_isolates[, 20:25], property = "atc")),
c("J01DC01", "J01DD01", "J01DD02", "J01DD04", "J01GB03", "J01GB01"))
if (AMR:::pkg_is_available("dplyr", min_version = "1.0.0")) {
expect_identical(example_isolates %>% set_ab_names(),

View File

@ -176,7 +176,7 @@ if (require("dplyr")) {
# set_ab_names() works with any AB property:
example_isolates \%>\%
set_ab_names("atc")
set_ab_names(property = "atc")
example_isolates \%>\%
set_ab_names(where(is.rsi)) \%>\%