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

cli-147-2226

This commit is contained in:
github-actions 2024-05-20 17:04:05 +00:00
parent bb51c7b8b3
commit 704eb041fa
89 changed files with 329 additions and 269 deletions

View File

@ -37,7 +37,7 @@
<a class="navbar-brand me-2" href="https://msberends.github.io/AMR/index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -205,7 +205,7 @@
website update since they are based on randomly created values and the
page was written in <a href="https://rmarkdown.rstudio.com/" class="external-link">R
Markdown</a>. However, the methodology remains unchanged. This page was
generated on 12 May 2024.</p>
generated on 20 May 2024.</p>
<div class="section level2">
<h2 id="introduction">Introduction<a class="anchor" aria-label="anchor" href="#introduction"></a>
</h2>
@ -261,21 +261,21 @@ make the structure of your data generally look like this:</p>
</tr></thead>
<tbody>
<tr class="odd">
<td align="center">2024-05-12</td>
<td align="center">2024-05-20</td>
<td align="center">abcd</td>
<td align="center">Escherichia coli</td>
<td align="center">S</td>
<td align="center">S</td>
</tr>
<tr class="even">
<td align="center">2024-05-12</td>
<td align="center">2024-05-20</td>
<td align="center">abcd</td>
<td align="center">Escherichia coli</td>
<td align="center">S</td>
<td align="center">R</td>
</tr>
<tr class="odd">
<td align="center">2024-05-12</td>
<td align="center">2024-05-20</td>
<td align="center">efgh</td>
<td align="center">Escherichia coli</td>
<td align="center">R</td>
@ -318,8 +318,9 @@ have extracted from their laboratory systems:</p>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 8</span> M3 A 2015-10-25 E. coli R S S S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 9</span> J3 A 2019-06-19 E. coli S S S S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">10</span> G6 A 2015-04-27 S. aureus S S S S </span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,990 more rows</span></span></span>
<span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,990 more rows</span></span></span></code></pre></div>
<div class="sourceCode" id="cb3"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="co"># we will use 'our_data' as the data set name for this tutorial</span></span>
<span><span class="va">our_data</span> <span class="op">&lt;-</span> <span class="va">example_isolates_unclean</span></span></code></pre></div>
<p>For AMR data analysis, we would like the microorganism column to
@ -336,17 +337,20 @@ included data were retrieved on 11 Dec 2022.</p>
<p>The codes of the AMR packages that come from <code><a href="../reference/as.mo.html">as.mo()</a></code> are
short, but still human readable. More importantly, <code><a href="../reference/as.mo.html">as.mo()</a></code>
supports all kinds of input:</p>
<div class="sourceCode" id="cb3"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb4"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="st">"Klebsiella pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; Class 'mo'</span></span>
<span><span class="co">#&gt; [1] B_KLBSL_PNMN</span></span>
<span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] B_KLBSL_PNMN</span></span></code></pre></div>
<div class="sourceCode" id="cb5"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; Class 'mo'</span></span>
<span><span class="co">#&gt; [1] B_KLBSL_PNMN</span></span>
<span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="st">"KLEPNE"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] B_KLBSL_PNMN</span></span></code></pre></div>
<div class="sourceCode" id="cb6"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="st">"KLEPNE"</span><span class="op">)</span></span>
<span><span class="co">#&gt; Class 'mo'</span></span>
<span><span class="co">#&gt; [1] B_KLBSL_PNMN</span></span>
<span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="st">"KLPN"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] B_KLBSL_PNMN</span></span></code></pre></div>
<div class="sourceCode" id="cb7"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="st">"KLPN"</span><span class="op">)</span></span>
<span><span class="co">#&gt; Class 'mo'</span></span>
<span><span class="co">#&gt; [1] B_KLBSL_PNMN</span></span></code></pre></div>
<p>The first character in above codes denote their taxonomic kingdom,
@ -356,33 +360,38 @@ retrieve taxonomic properties, such as the name, genus, species, family,
order, and even Gram-stain. They all start with <code>mo_</code> and
they use <code><a href="../reference/as.mo.html">as.mo()</a></code> internally, so that still any arbitrary
user input can be used:</p>
<div class="sourceCode" id="cb4"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb8"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/mo_property.html">mo_family</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] "Enterobacteriaceae"</span></span>
<span><span class="fu"><a href="../reference/mo_property.html">mo_genus</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] "Klebsiella"</span></span>
<span><span class="fu"><a href="../reference/mo_property.html">mo_species</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] "pneumoniae"</span></span>
<span></span>
<span><span class="co">#&gt; [1] "Enterobacteriaceae"</span></span></code></pre></div>
<div class="sourceCode" id="cb9"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/mo_property.html">mo_genus</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] "Klebsiella"</span></span></code></pre></div>
<div class="sourceCode" id="cb10"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/mo_property.html">mo_species</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] "pneumoniae"</span></span></code></pre></div>
<div class="sourceCode" id="cb11"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="fu"><a href="../reference/mo_property.html">mo_gramstain</a></span><span class="op">(</span><span class="st">"Klebsiella pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] "Gram-negative"</span></span>
<span></span>
<span><span class="co">#&gt; [1] "Gram-negative"</span></span></code></pre></div>
<div class="sourceCode" id="cb12"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="fu"><a href="../reference/mo_property.html">mo_ref</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] "Trevisan, 1887"</span></span>
<span></span>
<span><span class="co">#&gt; [1] "Trevisan, 1887"</span></span></code></pre></div>
<div class="sourceCode" id="cb13"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="fu"><a href="../reference/mo_property.html">mo_snomed</a></span><span class="op">(</span><span class="st">"K. pneumoniae"</span><span class="op">)</span></span>
<span><span class="co">#&gt; [[1]]</span></span>
<span><span class="co">#&gt; [1] "1098101000112102" "446870005" "1098201000112108" "409801009" </span></span>
<span><span class="co">#&gt; [5] "56415008" "714315002" "713926009"</span></span></code></pre></div>
<p>Now we can thus clean our data:</p>
<div class="sourceCode" id="cb5"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb14"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data</span><span class="op">$</span><span class="va">bacteria</span> <span class="op">&lt;-</span> <span class="fu"><a href="../reference/as.mo.html">as.mo</a></span><span class="op">(</span><span class="va">our_data</span><span class="op">$</span><span class="va">bacteria</span>, info <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span></span>
<span><span class="co">#&gt; Microorganism translation was uncertain for four microorganisms. Run</span></span>
<span><span class="co">#&gt; mo_uncertainties() to review these uncertainties, or use</span></span>
<span><span class="co">#&gt; add_custom_microorganisms() to add custom entries.</span></span></code></pre></div>
<p>Apparently, there was some uncertainty about the translation to
taxonomic codes. Lets check this:</p>
<div class="sourceCode" id="cb6"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb15"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/as.mo.html">mo_uncertainties</a></span><span class="op">(</span><span class="op">)</span></span>
<span><span class="co">#&gt; Matching scores are based on the resemblance between the input and the full</span></span>
<span><span class="co">#&gt; taxonomic name, and the pathogenicity in humans. See ?mo_matching_score.</span></span>
@ -439,7 +448,7 @@ diffusion values, read more about that on the <code><a href="../reference/as.sir
page.</p>
<p>For now, we will just clean the SIR columns in our data using
dplyr:</p>
<div class="sourceCode" id="cb7"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb16"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="co"># method 1, be explicit about the columns:</span></span>
<span><span class="va">our_data</span> <span class="op">&lt;-</span> <span class="va">our_data</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/mutate_all.html" class="external-link">mutate_at</a></span><span class="op">(</span><span class="fu"><a href="https://dplyr.tidyverse.org/reference/vars.html" class="external-link">vars</a></span><span class="op">(</span><span class="va">AMX</span><span class="op">:</span><span class="va">GEN</span><span class="op">)</span>, <span class="va">as.sir</span><span class="op">)</span></span>
@ -507,7 +516,7 @@ analysis, but the default phenotype-based method is in any case the
method to properly correct for most duplicate isolates. Read more about
the methods on the <code><a href="../reference/first_isolate.html">first_isolate()</a></code> page.</p>
<p>The outcome of the function can easily be added to our data:</p>
<div class="sourceCode" id="cb8"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb17"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data</span> <span class="op">&lt;-</span> <span class="va">our_data</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/mutate.html" class="external-link">mutate</a></span><span class="op">(</span>first <span class="op">=</span> <span class="fu"><a href="../reference/first_isolate.html">first_isolate</a></span><span class="op">(</span>info <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span><span class="op">)</span></span>
<span><span class="co">#&gt; Determining first isolates using an episode length of 365 days</span></span>
@ -521,16 +530,16 @@ the methods on the <code><a href="../reference/first_isolate.html">first_isolate
<p>So only 90% is suitable for resistance analysis! We can now filter on
it with the <code><a href="https://dplyr.tidyverse.org/reference/filter.html" class="external-link">filter()</a></code> function, also from the
<code>dplyr</code> package:</p>
<div class="sourceCode" id="cb9"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb18"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data_1st</span> <span class="op">&lt;-</span> <span class="va">our_data</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/filter.html" class="external-link">filter</a></span><span class="op">(</span><span class="va">first</span> <span class="op">==</span> <span class="cn">TRUE</span><span class="op">)</span></span></code></pre></div>
<p>For future use, the above two syntaxes can be shortened:</p>
<div class="sourceCode" id="cb10"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb19"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data_1st</span> <span class="op">&lt;-</span> <span class="va">our_data</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="../reference/first_isolate.html">filter_first_isolate</a></span><span class="op">(</span><span class="op">)</span></span></code></pre></div>
<p>So we end up with 2 712 isolates for analysis. Now our data looks
like:</p>
<div class="sourceCode" id="cb11"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb20"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data_1st</span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># A tibble: 2,712 × 9</span></span></span>
<span><span class="co">#&gt; patient_id hospital date bacteria AMX AMC CIP GEN first</span></span>
@ -555,7 +564,7 @@ like:</p>
<p>The base R <code><a href="https://rdrr.io/r/base/summary.html" class="external-link">summary()</a></code> function gives a good first
impression, as it comes with support for the new <code>mo</code> and
<code>sir</code> classes that we now have in our data set:</p>
<div class="sourceCode" id="cb12"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb21"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="https://rdrr.io/r/base/summary.html" class="external-link">summary</a></span><span class="op">(</span><span class="va">our_data_1st</span><span class="op">)</span></span>
<span><span class="co">#&gt; patient_id hospital date </span></span>
<span><span class="co">#&gt; Length:2712 Length:2712 Min. :2011-01-01 </span></span>
@ -577,8 +586,9 @@ impression, as it comes with support for the new <code>mo</code> and
<span><span class="co">#&gt; %SI :58.0% (n=1574) %SI :62.7% (n=1701) </span></span>
<span><span class="co">#&gt; - %S :51.5% (n=1396) - %S :59.6% (n=1616) </span></span>
<span><span class="co">#&gt; - %I : 6.6% (n=178) - %I : 3.1% (n=85) </span></span>
<span><span class="co">#&gt; </span></span>
<span></span>
<span><span class="co">#&gt; </span></span></code></pre></div>
<div class="sourceCode" id="cb22"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="fu"><a href="https://pillar.r-lib.org/reference/glimpse.html" class="external-link">glimpse</a></span><span class="op">(</span><span class="va">our_data_1st</span><span class="op">)</span></span>
<span><span class="co">#&gt; Rows: 2,712</span></span>
<span><span class="co">#&gt; Columns: 9</span></span>
@ -590,8 +600,9 @@ impression, as it comes with support for the new <code>mo</code> and
<span><span class="co">#&gt; $ AMC <span style="color: #949494; font-style: italic;">&lt;sir&gt;</span> I, I, I, S, S, S, S, S, S, S, S, S, I, S, S, S, S, R, S, S,…</span></span>
<span><span class="co">#&gt; $ CIP <span style="color: #949494; font-style: italic;">&lt;sir&gt;</span> S, S, S, S, R, S, S, S, S, S, S, S, S, S, S, S, S, S, S, S,…</span></span>
<span><span class="co">#&gt; $ GEN <span style="color: #949494; font-style: italic;">&lt;sir&gt;</span> S, S, S, S, S, S, S, S, S, S, R, S, S, S, S, S, S, S, S, S,…</span></span>
<span><span class="co">#&gt; $ first <span style="color: #949494; font-style: italic;">&lt;lgl&gt;</span> TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,…</span></span>
<span></span>
<span><span class="co">#&gt; $ first <span style="color: #949494; font-style: italic;">&lt;lgl&gt;</span> TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE,…</span></span></code></pre></div>
<div class="sourceCode" id="cb23"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="co"># number of unique values per column:</span></span>
<span><span class="fu"><a href="https://rdrr.io/r/base/lapply.html" class="external-link">sapply</a></span><span class="op">(</span><span class="va">our_data_1st</span>, <span class="va">n_distinct</span><span class="op">)</span></span>
<span><span class="co">#&gt; patient_id hospital date bacteria AMX AMC CIP </span></span>
@ -604,7 +615,7 @@ impression, as it comes with support for the new <code>mo</code> and
<p>To just get an idea how the species are distributed, create a
frequency table with <code><a href="../reference/count.html">count()</a></code> based on the name of the
microorganisms:</p>
<div class="sourceCode" id="cb13"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb24"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="../reference/count.html">count</a></span><span class="op">(</span><span class="fu"><a href="../reference/mo_property.html">mo_name</a></span><span class="op">(</span><span class="va">bacteria</span><span class="op">)</span>, sort <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># A tibble: 4 × 2</span></span></span>
@ -613,8 +624,9 @@ microorganisms:</p>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">1</span> Escherichia coli <span style="text-decoration: underline;">1</span>518</span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">2</span> Staphylococcus aureus 730</span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">3</span> Streptococcus pneumoniae 426</span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">4</span> Klebsiella pneumoniae 326</span></span>
<span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">4</span> Klebsiella pneumoniae 326</span></span></code></pre></div>
<div class="sourceCode" id="cb25"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="../reference/count.html">count</a></span><span class="op">(</span><span class="fu"><a href="../reference/mo_property.html">mo_name</a></span><span class="op">(</span><span class="va">bacteria</span><span class="op">)</span>, sort <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># A tibble: 4 × 2</span></span></span>
@ -631,7 +643,7 @@ microorganisms:</p>
<p>Using so-called antibiotic class selectors, you can select or filter
columns based on the antibiotic class that your antibiotic results are
in:</p>
<div class="sourceCode" id="cb14"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb26"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/select.html" class="external-link">select</a></span><span class="op">(</span><span class="va">date</span>, <span class="fu"><a href="../reference/antibiotic_class_selectors.html">aminoglycosides</a></span><span class="op">(</span><span class="op">)</span><span class="op">)</span></span>
<span><span class="co">#&gt; For aminoglycosides() using column 'GEN' (gentamicin)</span></span>
@ -648,8 +660,9 @@ in:</p>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 8</span> 2015-04-27 S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 9</span> 2011-06-21 S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">10</span> 2014-09-05 S </span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,702 more rows</span></span></span>
<span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,702 more rows</span></span></span></code></pre></div>
<div class="sourceCode" id="cb27"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/select.html" class="external-link">select</a></span><span class="op">(</span><span class="va">bacteria</span>, <span class="fu"><a href="../reference/antibiotic_class_selectors.html">betalactams</a></span><span class="op">(</span><span class="op">)</span><span class="op">)</span></span>
<span><span class="co">#&gt; For betalactams() using columns 'AMX' (amoxicillin) and 'AMC'</span></span>
@ -667,8 +680,9 @@ in:</p>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 8</span> B_STPHY_AURS S S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 9</span> B_ESCHR_COLI S S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">10</span> B_ESCHR_COLI S S </span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,702 more rows</span></span></span>
<span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,702 more rows</span></span></span></code></pre></div>
<div class="sourceCode" id="cb28"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/select.html" class="external-link">select</a></span><span class="op">(</span><span class="va">bacteria</span>, <span class="fu"><a href="https://tidyselect.r-lib.org/reference/where.html" class="external-link">where</a></span><span class="op">(</span><span class="va">is.sir</span><span class="op">)</span><span class="op">)</span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># A tibble: 2,712 × 5</span></span></span>
@ -684,8 +698,9 @@ in:</p>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 8</span> B_STPHY_AURS S S S S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 9</span> B_ESCHR_COLI S S S S </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">10</span> B_ESCHR_COLI S S S S </span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,702 more rows</span></span></span>
<span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 2,702 more rows</span></span></span></code></pre></div>
<div class="sourceCode" id="cb29"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="co"># filtering using AB selectors is also possible:</span></span>
<span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/filter.html" class="external-link">filter</a></span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/base/any.html" class="external-link">any</a></span><span class="op">(</span><span class="fu"><a href="../reference/antibiotic_class_selectors.html">aminoglycosides</a></span><span class="op">(</span><span class="op">)</span> <span class="op">==</span> <span class="st">"R"</span><span class="op">)</span><span class="op">)</span></span>
@ -703,8 +718,9 @@ in:</p>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 8</span> P5 A 2019-03-09 B_STPHY_AURS S S S R TRUE </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 9</span> Q8 A 2019-08-10 B_STPHY_AURS S S S R TRUE </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">10</span> K5 A 2013-03-15 B_STRPT_PNMN S S S R TRUE </span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 1,001 more rows</span></span></span>
<span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 1,001 more rows</span></span></span></code></pre></div>
<div class="sourceCode" id="cb30"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/filter.html" class="external-link">filter</a></span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/base/all.html" class="external-link">all</a></span><span class="op">(</span><span class="fu"><a href="../reference/antibiotic_class_selectors.html">betalactams</a></span><span class="op">(</span><span class="op">)</span> <span class="op">==</span> <span class="st">"R"</span><span class="op">)</span><span class="op">)</span></span>
<span><span class="co">#&gt; For betalactams() using columns 'AMX' (amoxicillin) and 'AMC'</span></span>
@ -722,8 +738,9 @@ in:</p>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 8</span> Q2 A 2019-09-22 B_ESCHR_COLI R R S S TRUE </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;"> 9</span> X7 A 2011-03-20 B_ESCHR_COLI R R S R TRUE </span></span>
<span><span class="co">#&gt; <span style="color: #BCBCBC;">10</span> V1 A 2018-08-07 B_STPHY_AURS R R S S TRUE </span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 473 more rows</span></span></span>
<span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># 473 more rows</span></span></span></code></pre></div>
<div class="sourceCode" id="cb31"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="co"># even works in base R (since R 3.0):</span></span>
<span><span class="va">our_data_1st</span><span class="op">[</span><span class="fu"><a href="https://rdrr.io/r/base/all.html" class="external-link">all</a></span><span class="op">(</span><span class="fu"><a href="../reference/antibiotic_class_selectors.html">betalactams</a></span><span class="op">(</span><span class="op">)</span> <span class="op">==</span> <span class="st">"R"</span><span class="op">)</span>, <span class="op">]</span></span>
<span><span class="co">#&gt; For betalactams() using columns 'AMX' (amoxicillin) and 'AMC'</span></span>
@ -776,7 +793,7 @@ failure</li>
function to create any of the above antibiogram types. For starters,
this is what the included <code>example_isolates</code> data set looks
like:</p>
<div class="sourceCode" id="cb15"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb32"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">example_isolates</span></span>
<span><span class="co">#&gt; <span style="color: #949494;"># A tibble: 2,000 × 46</span></span></span>
<span><span class="co">#&gt; date patient age gender ward mo PEN OXA FLC AMX </span></span>
@ -805,7 +822,7 @@ like:</p>
should be used. The <code>antibiotics</code> argument in the
<code><a href="../reference/antibiogram.html">antibiogram()</a></code> function supports any (combination) of the
previously mentioned antibiotic class selectors:</p>
<div class="sourceCode" id="cb16"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb33"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/antibiogram.html">antibiogram</a></span><span class="op">(</span><span class="va">example_isolates</span>,</span>
<span> antibiotics <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="fu"><a href="../reference/antibiotic_class_selectors.html">aminoglycosides</a></span><span class="op">(</span><span class="op">)</span>, <span class="fu"><a href="../reference/antibiotic_class_selectors.html">carbapenems</a></span><span class="op">(</span><span class="op">)</span><span class="op">)</span><span class="op">)</span></span>
<span><span class="co">#&gt; For aminoglycosides() using columns 'GEN' (gentamicin), 'TOB'</span></span>
@ -932,7 +949,7 @@ Chinese, Czech, Danish, Dutch, Finnish, French, German, Greek, Italian,
Japanese, Norwegian, Polish, Portuguese, Romanian, Russian, Spanish,
Swedish, Turkish, or Ukrainian. In this next example, we force the
language to be Spanish using the <code>language</code> argument:</p>
<div class="sourceCode" id="cb17"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb34"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/antibiogram.html">antibiogram</a></span><span class="op">(</span><span class="va">example_isolates</span>,</span>
<span> mo_transform <span class="op">=</span> <span class="st">"gramstain"</span>,</span>
<span> antibiotics <span class="op">=</span> <span class="fu"><a href="../reference/antibiotic_class_selectors.html">aminoglycosides</a></span><span class="op">(</span><span class="op">)</span>,</span>
@ -978,7 +995,7 @@ language to be Spanish using the <code>language</code> argument:</p>
</h4>
<p>To create a combined antibiogram, use antibiotic codes or names with
a plus <code>+</code> character like this:</p>
<div class="sourceCode" id="cb18"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb35"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/antibiogram.html">antibiogram</a></span><span class="op">(</span><span class="va">example_isolates</span>,</span>
<span> antibiotics <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="st">"TZP"</span>, <span class="st">"TZP+TOB"</span>, <span class="st">"TZP+GEN"</span><span class="op">)</span><span class="op">)</span></span></code></pre></div>
<table class="table">
@ -1060,7 +1077,7 @@ a plus <code>+</code> character like this:</p>
<p>To create a syndromic antibiogram, the <code>syndromic_group</code>
argument must be used. This can be any column in the data, or e.g. an
<code><a href="https://rdrr.io/r/base/ifelse.html" class="external-link">ifelse()</a></code> with calculations based on certain columns:</p>
<div class="sourceCode" id="cb19"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb36"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/antibiogram.html">antibiogram</a></span><span class="op">(</span><span class="va">example_isolates</span>,</span>
<span> antibiotics <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="fu"><a href="../reference/antibiotic_class_selectors.html">aminoglycosides</a></span><span class="op">(</span><span class="op">)</span>, <span class="fu"><a href="../reference/antibiotic_class_selectors.html">carbapenems</a></span><span class="op">(</span><span class="op">)</span><span class="op">)</span>,</span>
<span> syndromic_group <span class="op">=</span> <span class="st">"ward"</span><span class="op">)</span></span>
@ -1254,7 +1271,7 @@ Antibiogram) in which cases are predefined based on clinical or
demographic characteristics (e.g., endocarditis in 75+ females). This
next example is a simplification without clinical characteristics, but
just gives an idea of how a WISCA can be created:</p>
<div class="sourceCode" id="cb20"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb37"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">wisca</span> <span class="op">&lt;-</span> <span class="fu"><a href="../reference/antibiogram.html">antibiogram</a></span><span class="op">(</span><span class="va">example_isolates</span>,</span>
<span> antibiotics <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="st">"AMC"</span>, <span class="st">"AMC+CIP"</span>, <span class="st">"TZP"</span>, <span class="st">"TZP+TOB"</span><span class="op">)</span>,</span>
<span> mo_transform <span class="op">=</span> <span class="st">"gramstain"</span>,</span>
@ -1322,7 +1339,7 @@ just gives an idea of how a WISCA can be created:</p>
<p>Antibiograms can be plotted using <code><a href="https://ggplot2.tidyverse.org/reference/autoplot.html" class="external-link">autoplot()</a></code> from the
<code>ggplot2</code> packages, since this <code>AMR</code> package
provides an extension to that function:</p>
<div class="sourceCode" id="cb21"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb38"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="https://ggplot2.tidyverse.org/reference/autoplot.html" class="external-link">autoplot</a></span><span class="op">(</span><span class="va">wisca</span><span class="op">)</span></span></code></pre></div>
<p><img src="AMR_files/figure-html/unnamed-chunk-10-1.png" width="720"></p>
<p>To calculate antimicrobial resistance in a more sensible way, also by
@ -1351,12 +1368,12 @@ proportion of R (<code><a href="../reference/proportion.html">proportion_R()</a>
I (<code><a href="../reference/proportion.html">proportion_SI()</a></code>, equal to
<code><a href="../reference/proportion.html">susceptibility()</a></code>). These functions can be used on their
own:</p>
<div class="sourceCode" id="cb22"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb39"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span> <span class="fu"><a href="../reference/proportion.html">resistance</a></span><span class="op">(</span><span class="va">AMX</span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] 0.4288348</span></span></code></pre></div>
<p>Or can be used in conjunction with <code><a href="https://dplyr.tidyverse.org/reference/group_by.html" class="external-link">group_by()</a></code> and
<code><a href="https://dplyr.tidyverse.org/reference/summarise.html" class="external-link">summarise()</a></code>, both from the <code>dplyr</code> package:</p>
<div class="sourceCode" id="cb23"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb40"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">our_data_1st</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/group_by.html" class="external-link">group_by</a></span><span class="op">(</span><span class="va">hospital</span><span class="op">)</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span>
<span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/summarise.html" class="external-link">summarise</a></span><span class="op">(</span>amoxicillin <span class="op">=</span> <span class="fu"><a href="../reference/proportion.html">resistance</a></span><span class="op">(</span><span class="va">AMX</span><span class="op">)</span><span class="op">)</span></span>

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -248,8 +248,9 @@ be applied using <code><a href="../reference/eucast_rules.html">eucast_rules()</
<span><span class="va">oops</span></span>
<span><span class="co">#&gt; mo ampicillin</span></span>
<span><span class="co">#&gt; 1 Klebsiella S</span></span>
<span><span class="co">#&gt; 2 Escherichia S</span></span>
<span></span>
<span><span class="co">#&gt; 2 Escherichia S</span></span></code></pre></div>
<div class="sourceCode" id="cb2"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="fu"><a href="../reference/eucast_rules.html">eucast_rules</a></span><span class="op">(</span><span class="va">oops</span>, info <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span><span class="co">#&gt; mo ampicillin</span></span>
<span><span class="co">#&gt; 1 Klebsiella R</span></span>
@ -258,13 +259,14 @@ be applied using <code><a href="../reference/eucast_rules.html">eucast_rules()</
<code><a href="../reference/mo_property.html">mo_is_intrinsic_resistant()</a></code> that uses the same guideline,
but allows to check for one or more specific microorganisms or
antibiotics:</p>
<div class="sourceCode" id="cb2"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb3"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/mo_property.html">mo_is_intrinsic_resistant</a></span><span class="op">(</span></span>
<span> <span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="st">"Klebsiella"</span>, <span class="st">"Escherichia"</span><span class="op">)</span>,</span>
<span> <span class="st">"ampicillin"</span></span>
<span><span class="op">)</span></span>
<span><span class="co">#&gt; [1] TRUE FALSE</span></span>
<span></span>
<span><span class="co">#&gt; [1] TRUE FALSE</span></span></code></pre></div>
<div class="sourceCode" id="cb4"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="fu"><a href="../reference/mo_property.html">mo_is_intrinsic_resistant</a></span><span class="op">(</span></span>
<span> <span class="st">"Klebsiella"</span>,</span>
<span> <span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="st">"ampicillin"</span>, <span class="st">"kanamycin"</span><span class="op">)</span></span>
@ -275,7 +277,7 @@ used for filling in known resistance and susceptibility based on results
of other antimicrobials drugs. This process is called <em>interpretive
reading</em>, is basically a form of imputation, and is part of the
<code><a href="../reference/eucast_rules.html">eucast_rules()</a></code> function as well:</p>
<div class="sourceCode" id="cb3"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb5"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">data</span> <span class="op">&lt;-</span> <span class="fu"><a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a></span><span class="op">(</span></span>
<span> mo <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span></span>
<span> <span class="st">"Staphylococcus aureus"</span>,</span>
@ -293,7 +295,7 @@ reading</em>, is basically a form of imputation, and is part of the
<span> FOX <span class="op">=</span> <span class="st">"S"</span>, <span class="co"># Cefoxitin</span></span>
<span> stringsAsFactors <span class="op">=</span> <span class="cn">FALSE</span></span>
<span><span class="op">)</span></span></code></pre></div>
<div class="sourceCode" id="cb4"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb6"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="va">data</span></span></code></pre></div>
<table class="table">
<thead><tr class="header">
@ -359,7 +361,7 @@ reading</em>, is basically a form of imputation, and is part of the
</tr>
</tbody>
</table>
<div class="sourceCode" id="cb5"><pre class="downlit sourceCode r">
<div class="sourceCode" id="cb7"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="../reference/eucast_rules.html">eucast_rules</a></span><span class="op">(</span><span class="va">data</span><span class="op">)</span></span></code></pre></div>
<table class="table">
<thead><tr class="header">

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -372,7 +372,7 @@ Longest: 40</p>
<p><strong>Frequency table</strong></p>
<p>Class: factor &gt; ordered &gt; sir (numeric)<br>
Length: 500<br>
Levels: 3: S &lt; I &lt; R<br>
Levels: 5: S &lt; SDD &lt; I &lt; R &lt; N<br>
Available: 481 (96.2%, NA: 19 = 3.8%)<br>
Unique: 3</p>
<p>Drug: Amoxicillin/clavulanic acid (AMC, J01CR02)<br>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 61 KiB

After

Width:  |  Height:  |  Size: 61 KiB

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -194,7 +194,7 @@
<main id="main" class="col-md-9"><div class="page-header">
<img src="../logo.svg" class="logo" alt=""><h1>Data sets for download / own use</h1>
<h4 data-toc-skip class="date">12 May 2024</h4>
<h4 data-toc-skip class="date">20 May 2024</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>
<div class="d-none name"><code>datasets.Rmd</code></div>

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -362,8 +362,9 @@ model might be more appropriate:</p>
<span><span class="fu"><a href="https://rdrr.io/r/base/summary.html" class="external-link">summary</a></span><span class="op">(</span><span class="va">model</span><span class="op">)</span><span class="op">$</span><span class="va">family</span></span>
<span><span class="co">#&gt; </span></span>
<span><span class="co">#&gt; Family: binomial </span></span>
<span><span class="co">#&gt; Link function: logit</span></span>
<span></span>
<span><span class="co">#&gt; Link function: logit</span></span></code></pre></div>
<div class="sourceCode" id="cb10"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span></span>
<span><span class="fu"><a href="https://rdrr.io/r/base/summary.html" class="external-link">summary</a></span><span class="op">(</span><span class="va">model</span><span class="op">)</span><span class="op">$</span><span class="va">coefficients</span></span>
<span><span class="co">#&gt; Estimate Std. Error z value Pr(&gt;|z|)</span></span>
<span><span class="co">#&gt; (Intercept) -200.67944891 46.17315349 -4.346237 1.384932e-05</span></span>

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -39,7 +39,7 @@
<a class="navbar-brand me-2" href="index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -200,7 +200,7 @@
</li>
<li>Applies all recent <strong>CLSI and EUCAST clinical and veterinary breakpoints</strong> for MICs and disk zones</li>
<li>Corrects for duplicate isolates, <strong>calculates and predicts AMR</strong> per antibiotic class</li>
<li>Integrates with <strong>WHONET</strong>, ATC, <strong>EARS-Net</strong>, PubChem, <strong>LOINC</strong> and <strong>SNOMED CT</strong>
<li>Integrates with <strong>WHONET</strong>, ATC, <strong>EARS-Net</strong>, PubChem, <strong>LOINC</strong>, and <strong>SNOMED CT</strong>
</li>
<li>Works on Windows, macOS and Linux with <strong>all versions of R</strong> since R-3.0 and is completely <strong>dependency-free</strong>, highly suitable for places with <strong>limited resources</strong>
</li>
@ -777,7 +777,7 @@
<p>Manually, using:</p>
<div class="sourceCode" id="cb12"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu"><a href="https://rdrr.io/r/utils/install.packages.html" class="external-link">install.packages</a></span><span class="op">(</span><span class="st">"remotes"</span><span class="op">)</span> <span class="co"># if you haven't already</span></span>
<span><span class="fu">remotes</span><span class="fu">::</span><span class="fu">install_github</span><span class="op">(</span><span class="st">"msberends/AMR"</span><span class="op">)</span></span></code></pre></div>
<span><span class="fu">remotes</span><span class="fu">::</span><span class="fu"><a href="https://remotes.r-lib.org/reference/install_github.html" class="external-link">install_github</a></span><span class="op">(</span><span class="st">"msberends/AMR"</span><span class="op">)</span></span></code></pre></div>
</li>
<li>
<p>Automatically, using the <a href="https://ropensci.org/r-universe/" class="external-link">rOpenSci R-universe platform</a>, by adding <a href="https://msberends.r-universe.dev" class="external-link">our R-universe address</a> to your list of repositories (repos):</p>

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -159,18 +159,18 @@
</div>
<div class="section level2">
<h2 class="pkg-version" data-toc-text="2.1.1.9029" id="amr-2119029">AMR 2.1.1.9029<a class="anchor" aria-label="anchor" href="#amr-2119029"></a></h2>
<h2 class="pkg-version" data-toc-text="2.1.1.9031" id="amr-2119031">AMR 2.1.1.9031<a class="anchor" aria-label="anchor" href="#amr-2119031"></a></h2>
<p><em>(this beta version will eventually become v3.0. Were happy to reach a new major milestone soon, which will be all about the new One Health support!)</em></p>
<div class="section level5">
<h5 id="a-new-milestone-one-health-support--human--veterinary--environmental-2-1-1-9029">A New Milestone: One Health Support (= Human + Veterinary + Environmental)<a class="anchor" aria-label="anchor" href="#a-new-milestone-one-health-support--human--veterinary--environmental-2-1-1-9029"></a></h5>
<h5 id="a-new-milestone-one-health-support--human--veterinary--environmental-2-1-1-9031">A New Milestone: One Health Support (= Human + Veterinary + Environmental)<a class="anchor" aria-label="anchor" href="#a-new-milestone-one-health-support--human--veterinary--environmental-2-1-1-9031"></a></h5>
<p>This package now supports not only tools for AMR data analysis in clinical settings, but also for veterinary and environmental microbiology. This was made possible through a collaboration with the <a href="https://www.upei.ca/avc" class="external-link">University of Prince Edward Island</a>, Canada. To celebrate this great improvement of the package, we also updated the package logo to reflect this change.</p>
</div>
<div class="section level3">
<h3 id="breaking-2-1-1-9029">Breaking<a class="anchor" aria-label="anchor" href="#breaking-2-1-1-9029"></a></h3>
<h3 id="breaking-2-1-1-9031">Breaking<a class="anchor" aria-label="anchor" href="#breaking-2-1-1-9031"></a></h3>
<ul><li>Removed all functions and references that used the deprecated <code>rsi</code> class, which were all replaced with their <code>sir</code> equivalents over a year ago</li>
</ul></div>
<div class="section level3">
<h3 id="new-2-1-1-9029">New<a class="anchor" aria-label="anchor" href="#new-2-1-1-9029"></a></h3>
<h3 id="new-2-1-1-9031">New<a class="anchor" aria-label="anchor" href="#new-2-1-1-9031"></a></h3>
<ul><li>One Health implementation
<ul><li>Function <code><a href="../reference/as.sir.html">as.sir()</a></code> now has extensive support for animal breakpoints from CLSI. Use <code>breakpoint_type = "animal"</code> and set the <code>host</code> argument to a variable that contains animal species names.</li>
<li>The <code>clinical_breakpoints</code> data set contains all these breakpoints, and can be downloaded on our <a href="https://msberends.github.io/AMR/articles/datasets.html">download page</a>.</li>
@ -180,12 +180,14 @@
<li>
<code><a href="../reference/ab_property.html">ab_url()</a></code> now supports retrieving the WHOCC url of their ATCvet pages</li>
</ul></li>
<li>
<code><a href="../reference/as.sir.html">as.sir()</a></code> now returns additional factor levels “N” for non-interpretable and “SDD” for susceptible dose-dependent. Users can now set their own criteria (using regular expressions) as to what should be considered S, I, R, SDD, and N.</li>
<li>The function group <code>scale_*_mic()</code>, namely: <code><a href="../reference/plot.html">scale_x_mic()</a></code>, <code><a href="../reference/plot.html">scale_y_mic()</a></code>, <code><a href="../reference/plot.html">scale_colour_mic()</a></code> and <code><a href="../reference/plot.html">scale_fill_mic()</a></code>. They are advanced ggplot2 extensions to allow easy plotting of MIC values. They allow for manual range definition and plotting missing intermediate log2 levels.</li>
<li>Function <code><a href="../reference/as.mic.html">limit_mic_range()</a></code>, which allows to limit MIC values to a manually set range. This is the powerhouse behind the <code>scale_*_mic()</code> functions, but it can be used by users directly to e.g. compare equality in MIC distributions by rescaling them to the same range first.</li>
<li>Function <code><a href="../reference/mo_property.html">mo_group_members()</a></code> to retrieve the member microorganisms. For example, <code>mo_group_members("Strep group C")</code> returns a vector of all microorganisms that are in that group.</li>
</ul></div>
<div class="section level3">
<h3 id="changed-2-1-1-9029">Changed<a class="anchor" aria-label="anchor" href="#changed-2-1-1-9029"></a></h3>
<h3 id="changed-2-1-1-9031">Changed<a class="anchor" aria-label="anchor" href="#changed-2-1-1-9031"></a></h3>
<ul><li>For MICs:
<ul><li>Added as valid levels: 4096, 6 powers of 0.0625, and 5 powers of 192 (192, 384, 576, 768, 960)</li>
<li>Added new argument <code>keep_operators</code> to <code><a href="../reference/as.mic.html">as.mic()</a></code>. This can be <code>"all"</code> (default), <code>"none"</code>, or <code>"edges"</code>. This argument is also available in the new <code><a href="../reference/as.mic.html">limit_mic_range()</a></code> and <code>scale_*_mic()</code> functions.</li>
@ -203,7 +205,7 @@
<li>Improved overall algorithm of <code><a href="../reference/as.ab.html">as.ab()</a></code> for better performance and accuracy</li>
</ul></div>
<div class="section level3">
<h3 id="other-2-1-1-9029">Other<a class="anchor" aria-label="anchor" href="#other-2-1-1-9029"></a></h3>
<h3 id="other-2-1-1-9031">Other<a class="anchor" aria-label="anchor" href="#other-2-1-1-9031"></a></h3>
<ul><li>Added Jordan Stull, Matthew Saab, and Javier Sanchez as contributors, to thank them for their valuable input</li>
</ul></div>
</div>

View File

@ -11,7 +11,7 @@ articles:
resistance_predict: resistance_predict.html
welcome_to_AMR: welcome_to_AMR.html
WHONET: WHONET.html
last_built: 2024-05-12T14:29Z
last_built: 2024-05-20T17:01Z
urls:
reference: https://msberends.github.io/AMR/reference
article: https://msberends.github.io/AMR/articles

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -24,7 +24,7 @@ The AMR package is available in English, Chinese, Czech, Danish, Dutch, Finnish,
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.0 KiB

After

Width:  |  Height:  |  Size: 8.7 KiB

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -222,16 +222,16 @@
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="va">df</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> birth_date age age_exact age_at_y2k</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 1965-12-05 58 58.43443 34</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 1980-03-01 44 44.19672 19</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 1949-11-01 74 74.52732 50</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 1947-02-14 77 77.24044 52</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 1940-02-19 84 84.22678 59</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 1988-01-10 36 36.33607 11</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 1997-08-27 26 26.70765 2</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 1978-01-26 46 46.29235 21</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 1972-06-17 51 51.90164 27</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 1986-08-10 37 37.75410 13</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 1965-12-05 58 58.45628 34</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 1980-03-01 44 44.21858 19</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 1949-11-01 74 74.54918 50</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 1947-02-14 77 77.26230 52</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 1940-02-19 84 84.24863 59</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 1988-01-10 36 36.35792 11</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 1997-08-27 26 26.72951 2</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 1978-01-26 46 46.31421 21</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 1972-06-17 51 51.92350 27</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 1986-08-10 37 37.77596 13</span>
</code></pre></div>
</div>
</main><aside class="col-md-3"><nav id="toc"><h2>On this page</h2>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 42 KiB

After

Width:  |  Height:  |  Size: 43 KiB

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -12,7 +12,7 @@ In short, if you have a column name that resembles an antimicrobial drug, it wil
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -1,19 +1,19 @@
<!DOCTYPE html>
<!-- Generated by pkgdown: do not edit by hand --><html lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"><meta name="description" content="Clean up existing SIR values, or interpret minimum inhibitory concentration (MIC) values and disk diffusion diameters according to EUCAST or CLSI. as.sir() transforms the input to a new class sir, which is an ordered factor.
Currently breakpoints are available:
These breakpoints are currently available:
For clinical microbiology from EUCAST 2011-2023 and CLSI 2011-2023;
For veterinary microbiology from EUCAST 2021-2023 and CLSI 2019-2023;
ECOFFs (Epidemiological cut-off values) from EUCAST 2020-2023 and CLSI 2022-2023.
All breakpoints used for interpretation are publicly available in the clinical_breakpoints data set."><title>Translate MIC and Disk Diffusion to SIR, or Clean Existing SIR Data — as.sir • AMR (for R)</title><!-- favicons --><link rel="icon" type="image/png" sizes="16x16" href="../favicon-16x16.png"><link rel="icon" type="image/png" sizes="32x32" href="../favicon-32x32.png"><link rel="apple-touch-icon" type="image/png" sizes="180x180" href="../apple-touch-icon.png"><link rel="apple-touch-icon" type="image/png" sizes="120x120" href="../apple-touch-icon-120x120.png"><link rel="apple-touch-icon" type="image/png" sizes="76x76" href="../apple-touch-icon-76x76.png"><link rel="apple-touch-icon" type="image/png" sizes="60x60" href="../apple-touch-icon-60x60.png"><script src="../deps/jquery-3.6.0/jquery-3.6.0.min.js"></script><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"><link href="../deps/bootstrap-5.3.1/bootstrap.min.css" rel="stylesheet"><script src="../deps/bootstrap-5.3.1/bootstrap.bundle.min.js"></script><link href="../deps/Lato-0.4.9/font.css" rel="stylesheet"><link href="../deps/Fira_Code-0.4.9/font.css" rel="stylesheet"><!-- Font Awesome icons --><link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.1/css/all.min.css" integrity="sha256-mmgLkCYLUQbXn0B1SRqzHar6dCnv9oZFPEC1g1cwlkk=" crossorigin="anonymous"><link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.1/css/v4-shims.min.css" integrity="sha256-wZjR52fzng1pJHwx4aV2AO3yyTOXrcDW7jBpJtTwVxw=" crossorigin="anonymous"><!-- bootstrap-toc --><script src="https://cdn.jsdelivr.net/gh/afeld/bootstrap-toc@v1.0.1/dist/bootstrap-toc.min.js" integrity="sha256-4veVQbu7//Lk5TSmc7YV48MxtMy98e26cf5MrgZYnwo=" crossorigin="anonymous"></script><!-- headroom.js --><script src="https://cdnjs.cloudflare.com/ajax/libs/headroom/0.11.0/headroom.min.js" integrity="sha256-AsUX4SJE1+yuDu5+mAVzJbuYNPHj/WroHuZ8Ir/CkE0=" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/headroom/0.11.0/jQuery.headroom.min.js" integrity="sha256-ZX/yNShbjqsohH1k95liqY9Gd8uOiE1S4vZc+9KQ1K4=" crossorigin="anonymous"></script><!-- clipboard.js --><script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.11/clipboard.min.js" integrity="sha512-7O5pXpc0oCRrxk8RUfDYFgn0nO1t+jLuIOQdOMRp4APB7uZ4vSjspzp5y6YDtDs4VzUSTbWzBFZ/LKJhnyFOKw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script><!-- search --><script src="https://cdnjs.cloudflare.com/ajax/libs/fuse.js/6.4.6/fuse.js" integrity="sha512-zv6Ywkjyktsohkbp9bb45V6tEMoWhzFzXis+LrMehmJZZSys19Yxf1dopHx7WzIKxr5tK2dVcYmaCk2uqdjF4A==" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/autocomplete.js/0.38.0/autocomplete.jquery.min.js" integrity="sha512-GU9ayf+66Xx2TmpxqJpliWbT5PiGYxpaG8rfnBEk1LL8l1KGkRShhngwdXK1UgqhAzWpZHSiYPc09/NwDQIGyg==" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/mark.js/8.11.1/mark.min.js" integrity="sha512-5CYOlHXGh6QpOFA/TeTylKLWfB3ftPsde7AnmhuitiTX4K5SqCLBeKro6sPS8ilsz1Q4NRx3v8Ko2IBiszzdww==" crossorigin="anonymous"></script><!-- pkgdown --><script src="../pkgdown.js"></script><link href="../extra.css" rel="stylesheet"><script src="../extra.js"></script><meta property="og:title" content="Translate MIC and Disk Diffusion to SIR, or Clean Existing SIR Data — as.sir"><meta property="og:description" content="Clean up existing SIR values, or interpret minimum inhibitory concentration (MIC) values and disk diffusion diameters according to EUCAST or CLSI. as.sir() transforms the input to a new class sir, which is an ordered factor.
Currently breakpoints are available:
All breakpoints used for interpretation are available in our clinical_breakpoints data set."><title>Translate MIC and Disk Diffusion to SIR, or Clean Existing SIR Data — as.sir • AMR (for R)</title><!-- favicons --><link rel="icon" type="image/png" sizes="16x16" href="../favicon-16x16.png"><link rel="icon" type="image/png" sizes="32x32" href="../favicon-32x32.png"><link rel="apple-touch-icon" type="image/png" sizes="180x180" href="../apple-touch-icon.png"><link rel="apple-touch-icon" type="image/png" sizes="120x120" href="../apple-touch-icon-120x120.png"><link rel="apple-touch-icon" type="image/png" sizes="76x76" href="../apple-touch-icon-76x76.png"><link rel="apple-touch-icon" type="image/png" sizes="60x60" href="../apple-touch-icon-60x60.png"><script src="../deps/jquery-3.6.0/jquery-3.6.0.min.js"></script><meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"><link href="../deps/bootstrap-5.3.1/bootstrap.min.css" rel="stylesheet"><script src="../deps/bootstrap-5.3.1/bootstrap.bundle.min.js"></script><link href="../deps/Lato-0.4.9/font.css" rel="stylesheet"><link href="../deps/Fira_Code-0.4.9/font.css" rel="stylesheet"><!-- Font Awesome icons --><link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.1/css/all.min.css" integrity="sha256-mmgLkCYLUQbXn0B1SRqzHar6dCnv9oZFPEC1g1cwlkk=" crossorigin="anonymous"><link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.12.1/css/v4-shims.min.css" integrity="sha256-wZjR52fzng1pJHwx4aV2AO3yyTOXrcDW7jBpJtTwVxw=" crossorigin="anonymous"><!-- bootstrap-toc --><script src="https://cdn.jsdelivr.net/gh/afeld/bootstrap-toc@v1.0.1/dist/bootstrap-toc.min.js" integrity="sha256-4veVQbu7//Lk5TSmc7YV48MxtMy98e26cf5MrgZYnwo=" crossorigin="anonymous"></script><!-- headroom.js --><script src="https://cdnjs.cloudflare.com/ajax/libs/headroom/0.11.0/headroom.min.js" integrity="sha256-AsUX4SJE1+yuDu5+mAVzJbuYNPHj/WroHuZ8Ir/CkE0=" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/headroom/0.11.0/jQuery.headroom.min.js" integrity="sha256-ZX/yNShbjqsohH1k95liqY9Gd8uOiE1S4vZc+9KQ1K4=" crossorigin="anonymous"></script><!-- clipboard.js --><script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.11/clipboard.min.js" integrity="sha512-7O5pXpc0oCRrxk8RUfDYFgn0nO1t+jLuIOQdOMRp4APB7uZ4vSjspzp5y6YDtDs4VzUSTbWzBFZ/LKJhnyFOKw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script><!-- search --><script src="https://cdnjs.cloudflare.com/ajax/libs/fuse.js/6.4.6/fuse.js" integrity="sha512-zv6Ywkjyktsohkbp9bb45V6tEMoWhzFzXis+LrMehmJZZSys19Yxf1dopHx7WzIKxr5tK2dVcYmaCk2uqdjF4A==" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/autocomplete.js/0.38.0/autocomplete.jquery.min.js" integrity="sha512-GU9ayf+66Xx2TmpxqJpliWbT5PiGYxpaG8rfnBEk1LL8l1KGkRShhngwdXK1UgqhAzWpZHSiYPc09/NwDQIGyg==" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/mark.js/8.11.1/mark.min.js" integrity="sha512-5CYOlHXGh6QpOFA/TeTylKLWfB3ftPsde7AnmhuitiTX4K5SqCLBeKro6sPS8ilsz1Q4NRx3v8Ko2IBiszzdww==" crossorigin="anonymous"></script><!-- pkgdown --><script src="../pkgdown.js"></script><link href="../extra.css" rel="stylesheet"><script src="../extra.js"></script><meta property="og:title" content="Translate MIC and Disk Diffusion to SIR, or Clean Existing SIR Data — as.sir"><meta property="og:description" content="Clean up existing SIR values, or interpret minimum inhibitory concentration (MIC) values and disk diffusion diameters according to EUCAST or CLSI. as.sir() transforms the input to a new class sir, which is an ordered factor.
These breakpoints are currently available:
For clinical microbiology from EUCAST 2011-2023 and CLSI 2011-2023;
For veterinary microbiology from EUCAST 2021-2023 and CLSI 2019-2023;
ECOFFs (Epidemiological cut-off values) from EUCAST 2020-2023 and CLSI 2022-2023.
All breakpoints used for interpretation are publicly available in the clinical_breakpoints data set."><meta property="og:image" content="https://msberends.github.io/AMR/logo.svg"><meta name="twitter:card" content="summary_large_image"><meta name="twitter:creator" content="@msberends"><meta name="twitter:site" content="@msberends"><!-- mathjax --><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js" integrity="sha256-nvJJv9wWKEm88qvoQl9ekL2J+k/RWIsaSScxxlsrv8k=" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/config/TeX-AMS-MML_HTMLorMML.js" integrity="sha256-84DKXVJXs0/F8OTMzX4UR909+jtl4G7SPypPavF+GfA=" crossorigin="anonymous"></script><!--[if lt IE 9]>
All breakpoints used for interpretation are available in our clinical_breakpoints data set."><meta property="og:image" content="https://msberends.github.io/AMR/logo.svg"><meta name="twitter:card" content="summary_large_image"><meta name="twitter:creator" content="@msberends"><meta name="twitter:site" content="@msberends"><!-- mathjax --><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js" integrity="sha256-nvJJv9wWKEm88qvoQl9ekL2J+k/RWIsaSScxxlsrv8k=" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/config/TeX-AMS-MML_HTMLorMML.js" integrity="sha256-84DKXVJXs0/F8OTMzX4UR909+jtl4G7SPypPavF+GfA=" crossorigin="anonymous"></script><!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]--></head><body>
@ -24,7 +24,7 @@ All breakpoints used for interpretation are publicly available in the clinical_b
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -175,10 +175,10 @@ All breakpoints used for interpretation are publicly available in the clinical_b
<div class="ref-description section level2">
<p>Clean up existing SIR values, or interpret minimum inhibitory concentration (MIC) values and disk diffusion diameters according to EUCAST or CLSI. <code>as.sir()</code> transforms the input to a new class <code>sir</code>, which is an ordered <a href="https://rdrr.io/r/base/factor.html" class="external-link">factor</a>.</p>
<p>Currently breakpoints are available:</p><ul><li><p>For <strong>clinical microbiology</strong> from EUCAST 2011-2023 and CLSI 2011-2023;</p></li>
<p>These breakpoints are currently available:</p><ul><li><p>For <strong>clinical microbiology</strong> from EUCAST 2011-2023 and CLSI 2011-2023;</p></li>
<li><p>For <strong>veterinary microbiology</strong> from EUCAST 2021-2023 and CLSI 2019-2023;</p></li>
<li><p>ECOFFs (Epidemiological cut-off values) from EUCAST 2020-2023 and CLSI 2022-2023.</p></li>
</ul><p>All breakpoints used for interpretation are publicly available in the <a href="clinical_breakpoints.html">clinical_breakpoints</a> data set.</p>
</ul><p>All breakpoints used for interpretation are available in our <a href="clinical_breakpoints.html">clinical_breakpoints</a> data set.</p>
</div>
<div class="section level2">
@ -191,6 +191,17 @@ All breakpoints used for interpretation are publicly available in the clinical_b
<span></span>
<span><span class="fu">is_sir_eligible</span><span class="op">(</span><span class="va">x</span>, threshold <span class="op">=</span> <span class="fl">0.05</span><span class="op">)</span></span>
<span></span>
<span><span class="co"># S3 method for default</span></span>
<span><span class="fu">as.sir</span><span class="op">(</span></span>
<span> <span class="va">x</span>,</span>
<span> S <span class="op">=</span> <span class="st">"^(S|U)+$"</span>,</span>
<span> I <span class="op">=</span> <span class="st">"^(I|H)+$"</span>,</span>
<span> R <span class="op">=</span> <span class="st">"^(R)+$"</span>,</span>
<span> N <span class="op">=</span> <span class="st">"^(N|V)+$"</span>,</span>
<span> SDD <span class="op">=</span> <span class="st">"^(SDD|D)+$"</span>,</span>
<span> <span class="va">...</span></span>
<span><span class="op">)</span></span>
<span></span>
<span><span class="co"># S3 method for mic</span></span>
<span><span class="fu">as.sir</span><span class="op">(</span></span>
<span> <span class="va">x</span>,</span>
@ -264,6 +275,10 @@ All breakpoints used for interpretation are publicly available in the clinical_b
<dd><p>maximum fraction of invalid antimicrobial interpretations of <code>x</code>, see <em>Examples</em></p></dd>
<dt>S, I, R, N, SDD</dt>
<dd><p>a case-indepdendent <a href="https://rdrr.io/r/base/regex.html" class="external-link">regular expression</a> to translate input to this result. This regular expression will be run <em>after</em> all non-letters are removed from the input.</p></dd>
<dt>mo</dt>
<dd><p>any (vector of) text that can be coerced to valid microorganism codes with <code><a href="as.mo.html">as.mo()</a></code>, can be left empty to determine it automatically</p></dd>
@ -330,7 +345,7 @@ All breakpoints used for interpretation are publicly available in the clinical_b
<h3 id="how-it-works">How it Works<a class="anchor" aria-label="anchor" href="#how-it-works"></a></h3>
<p>The <code>as.sir()</code> function can work in four ways:</p><ol><li><p>For <strong>cleaning raw / untransformed data</strong>. The data will be cleaned to only contain values S, I and R and will try its best to determine this with some intelligence. For example, mixed values with SIR interpretations and MIC values such as <code>"&lt;0.25; S"</code> will be coerced to <code>"S"</code>. Combined interpretations for multiple test methods (as seen in laboratory records) such as <code>"S; S"</code> will be coerced to <code>"S"</code>, but a value like <code>"S; I"</code> will return <code>NA</code> with a warning that the input is unclear.</p></li>
<p>The <code>as.sir()</code> function can work in four ways:</p><ol><li><p>For <strong>cleaning raw / untransformed data</strong>. The data will be cleaned to only contain valid values, namely: <strong>S</strong> for susceptible, <strong>I</strong> for intermediate or 'susceptible, increased exposure', <strong>R</strong> for resistant, <strong>N</strong> for non-interpretable, and <strong>SDD</strong> for susceptible dose-dependent. Each of these can be set using a <a href="https://rdrr.io/r/base/regex.html" class="external-link">regular expression</a>. Furthermore, <code>as.sir()</code> will try its best to clean with some intelligence. For example, mixed values with SIR interpretations and MIC values such as <code>"&lt;0.25; S"</code> will be coerced to <code>"S"</code>. Combined interpretations for multiple test methods (as seen in laboratory records) such as <code>"S; S"</code> will be coerced to <code>"S"</code>, but a value like <code>"S; I"</code> will return <code>NA</code> with a warning that the input is invalid.</p></li>
<li><p>For <strong>interpreting minimum inhibitory concentration (MIC) values</strong> according to EUCAST or CLSI. You must clean your MIC values first using <code><a href="as.mic.html">as.mic()</a></code>, that also gives your columns the new data class <code><a href="as.mic.html">mic</a></code>. Also, be sure to have a column with microorganism names or codes. It will be found automatically, but can be set manually using the <code>mo</code> argument.</p><ul><li><p>Using <code>dplyr</code>, SIR interpretation can be done very easily with either:</p>
<p></p><div class="sourceCode"><pre><code><span id="cb1-1"><a href="#cb1-1" tabindex="-1"></a>your_data <span class="sc">%&gt;%</span> <span class="fu">mutate_if</span>(is.mic, as.sir)</span>
<span id="cb1-2"><a href="#cb1-2" tabindex="-1"></a>your_data <span class="sc">%&gt;%</span> <span class="fu">mutate</span>(<span class="fu">across</span>(<span class="fu">where</span>(is.mic), as.sir))</span>
@ -386,7 +401,7 @@ All breakpoints used for interpretation are publicly available in the clinical_b
<p>The function <code>is.sir()</code> detects if the input contains class <code>sir</code>. If the input is a <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a>, it iterates over all columns and returns a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> vector.</p>
<p>The function <code>is_sir_eligible()</code> returns <code>TRUE</code> when a columns contains at most 5% invalid antimicrobial interpretations (not S and/or I and/or R), and <code>FALSE</code> otherwise. The threshold of 5% can be set with the <code>threshold</code> argument. If the input is a <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a>, it iterates over all columns and returns a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> vector.</p>
<p>The function <code>is_sir_eligible()</code> returns <code>TRUE</code> when a columns contains at most 5% invalid antimicrobial interpretations (not S and/or I and/or R and/or N and/or SDD), and <code>FALSE</code> otherwise. The threshold of 5% can be set with the <code>threshold</code> argument. If the input is a <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a>, it iterates over all columns and returns a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> vector.</p>
</div>
<p><code>NA_sir_</code> is a missing value of the new <code>sir</code> class, analogous to e.g. base <span style="R">R</span>'s <code><a href="https://rdrr.io/r/base/NA.html" class="external-link">NA_character_</a></code>.</p>
@ -592,19 +607,19 @@ A microorganism is categorised as "Resistant" when there is a high likelihood of
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 13 × 14</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> datetime index ab_user mo_user ab mo input</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dttm&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;ab&gt;</span> <span style="color: #949494; font-style: italic;">&lt;mo&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> 2024-05-12 <span style="color: #949494;">14:30:32</span> 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 2024-05-12 <span style="color: #949494;">14:30:32</span> 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 2024-05-12 <span style="color: #949494;">14:30:32</span> 1 CIP Escherich… CIP B_[ORD]_ENTRBCTR 0.256</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> 2024-05-12 <span style="color: #949494;">14:30:32</span> 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 2024-05-12 <span style="color: #949494;">14:30:27</span> 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 0.01 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 2024-05-12 <span style="color: #949494;">14:30:27</span> 2 AMX B_STRPT_P… AMX B_STRPT_PNMN 2 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 2024-05-12 <span style="color: #949494;">14:30:27</span> 3 AMX B_STRPT_P… AMX B_STRPT_PNMN 4 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 2024-05-12 <span style="color: #949494;">14:30:27</span> 4 AMX B_STRPT_P… AMX B_STRPT_PNMN 8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> 2024-05-12 <span style="color: #949494;">14:30:27</span> 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 2 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 2024-05-12 <span style="color: #949494;">14:30:26</span> 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">11</span> 2024-05-12 <span style="color: #949494;">14:30:26</span> 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">12</span> 2024-05-12 <span style="color: #949494;">14:30:26</span> 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 20 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">13</span> 2024-05-12 <span style="color: #949494;">14:30:26</span> 1 ampicillin Strep pneu AMP B_STRPT_PNMN 18 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> 2024-05-20 <span style="color: #949494;">17:02:01</span> 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 2024-05-20 <span style="color: #949494;">17:02:00</span> 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 2024-05-20 <span style="color: #949494;">17:02:00</span> 1 CIP Escherich… CIP B_[ORD]_ENTRBCTR 0.256</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> 2024-05-20 <span style="color: #949494;">17:02:00</span> 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 2024-05-20 <span style="color: #949494;">17:01:56</span> 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 0.01 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 2024-05-20 <span style="color: #949494;">17:01:56</span> 2 AMX B_STRPT_P… AMX B_STRPT_PNMN 2 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 2024-05-20 <span style="color: #949494;">17:01:56</span> 3 AMX B_STRPT_P… AMX B_STRPT_PNMN 4 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 2024-05-20 <span style="color: #949494;">17:01:56</span> 4 AMX B_STRPT_P… AMX B_STRPT_PNMN 8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> 2024-05-20 <span style="color: #949494;">17:01:55</span> 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 2 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 2024-05-20 <span style="color: #949494;">17:01:55</span> 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">11</span> 2024-05-20 <span style="color: #949494;">17:01:55</span> 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">12</span> 2024-05-20 <span style="color: #949494;">17:01:55</span> 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 20 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">13</span> 2024-05-20 <span style="color: #949494;">17:01:55</span> 1 ampicillin Strep pneu AMP B_STRPT_PNMN 18 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># 7 more variables: outcome &lt;sir&gt;, method &lt;chr&gt;, breakpoint_S_R &lt;chr&gt;,</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># guideline &lt;chr&gt;, host &lt;chr&gt;, ref_table &lt;chr&gt;, uti &lt;lgl&gt;</span></span>
<span class="r-in"><span></span></span>
@ -837,11 +852,11 @@ A microorganism is categorised as "Resistant" when there is a high likelihood of
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># For CLEANING existing SIR values ------------------------------------</span></span></span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu">as.sir</span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="st">"S"</span>, <span class="st">"I"</span>, <span class="st">"R"</span>, <span class="st">"A"</span>, <span class="st">"B"</span>, <span class="st">"C"</span><span class="op">)</span><span class="op">)</span></span></span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> <span class="warning">Warning: </span>in as.sir(): 3 results in column '24' truncated (50%) that were invalid</span>
<span class="r-in"><span><span class="fu">as.sir</span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/base/c.html" class="external-link">c</a></span><span class="op">(</span><span class="st">"S"</span>, <span class="st">"SDD"</span>, <span class="st">"I"</span>, <span class="st">"R"</span>, <span class="st">"N"</span>, <span class="st">"A"</span>, <span class="st">"B"</span>, <span class="st">"C"</span><span class="op">)</span><span class="op">)</span></span></span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> <span class="warning">Warning: </span>in as.sir(): 3 results in column '24' truncated (38%) that were invalid</span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> antimicrobial interpretations: "A", "B", and "C"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'sir'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] S I R &lt;NA&gt; &lt;NA&gt; &lt;NA&gt;</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] S SDD I R N &lt;NA&gt; &lt;NA&gt; &lt;NA&gt;</span>
<span class="r-in"><span><span class="fu">as.sir</span><span class="op">(</span><span class="st">"&lt;= 0.002; S"</span><span class="op">)</span> <span class="co"># will return "S"</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'sir'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] S</span>

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -239,7 +239,7 @@
<h2 id="value">Value<a class="anchor" aria-label="anchor" href="#value"></a></h2>
<p>The function <code>bug_drug_combinations()</code> returns a <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a> with columns "mo", "ab", "S", "I", "R" and "total".</p>
<p>The function <code>bug_drug_combinations()</code> returns a <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a> with columns "mo", "ab", "S", "SDD", "I", "R", and "total".</p>
</div>
<div class="section level2">
<h2 id="details">Details<a class="anchor" aria-label="anchor" href="#details"></a></h2>
@ -275,15 +275,15 @@
<span class="r-in"><span><span class="co"># \donttest{</span></span></span>
<span class="r-in"><span><span class="va">x</span> <span class="op">&lt;-</span> <span class="fu">bug_drug_combinations</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">)</span></span></span>
<span class="r-in"><span><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">x</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 6 × 6</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> mo ab S I R total</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">1</span> (unknown species) AMC 15 0 0 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">2</span> (unknown species) AMK 0 0 0 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">3</span> (unknown species) AMP 15 0 1 16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">4</span> (unknown species) AMX 15 0 1 16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">5</span> (unknown species) AZM 3 0 3 6</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">6</span> (unknown species) CAZ 0 0 0 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 6 × 8</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> mo ab S SDD I R N total</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">1</span> (unknown species) AMC 15 0 0 0 0 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">2</span> (unknown species) AMK 0 0 0 0 0 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">3</span> (unknown species) AMP 15 0 0 1 0 16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">4</span> (unknown species) AMX 15 0 0 1 0 16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">5</span> (unknown species) AZM 3 0 0 3 0 6</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">6</span> (unknown species) CAZ 0 0 0 0 0 0</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Use 'format()' on this result to get a publishable/printable format.</span>
<span class="r-in"><span><span class="fu"><a href="https://rdrr.io/r/base/format.html" class="external-link">format</a></span><span class="op">(</span><span class="va">x</span>, translate_ab <span class="op">=</span> <span class="st">"name (atc)"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 39 × 12</span></span>
@ -307,19 +307,19 @@
<span class="r-in"><span><span class="fu">bug_drug_combinations</span><span class="op">(</span><span class="va">example_isolates</span>,</span></span>
<span class="r-in"><span> FUN <span class="op">=</span> <span class="va">mo_gramstain</span></span></span>
<span class="r-in"><span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 80 × 6</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> mo ab S I R total</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">*</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> Gram-negative AMC 463 89 174 726</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> Gram-negative AMK 251 0 5 256</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Gram-negative AMP 226 0 405 631</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> Gram-negative AMX 226 0 405 631</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> Gram-negative AZM 1 2 696 699</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> Gram-negative CAZ 607 0 27 634</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> Gram-negative CHL 1 0 30 31</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> Gram-negative CIP 610 11 63 684</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> Gram-negative CLI 18 1 709 728</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> Gram-negative COL 309 0 78 387</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 80 × 8</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> mo ab S SDD I R N total</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">*</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> Gram-negative AMC 463 0 89 174 0 726</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> Gram-negative AMK 251 0 0 5 0 256</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Gram-negative AMP 226 0 0 405 0 631</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> Gram-negative AMX 226 0 0 405 0 631</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> Gram-negative AZM 1 0 2 696 0 699</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> Gram-negative CAZ 607 0 0 27 0 634</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> Gram-negative CHL 1 0 0 30 0 31</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> Gram-negative CIP 610 0 11 63 0 684</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> Gram-negative CLI 18 0 1 709 0 728</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> Gram-negative COL 309 0 0 78 0 387</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># 70 more rows</span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Use 'format()' on this result to get a publishable/printable format.</span>
<span class="r-in"><span></span></span>
@ -331,19 +331,19 @@
<span class="r-in"><span> <span class="op">)</span></span></span>
<span class="r-in"><span> <span class="op">}</span></span></span>
<span class="r-in"><span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 80 × 6</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> mo ab S I R total</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">*</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> E. coli AMC 332 74 61 467</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> E. coli AMK 171 0 0 171</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> E. coli AMP 196 0 196 392</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> E. coli AMX 196 0 196 392</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> E. coli AZM 0 0 467 467</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> E. coli CAZ 449 0 11 460</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> E. coli CHL 0 0 0 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> E. coli CIP 398 1 57 456</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> E. coli CLI 0 0 467 467</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> E. coli COL 240 0 0 240</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 80 × 8</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> mo ab S SDD I R N total</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">*</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> E. coli AMC 332 0 74 61 0 467</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> E. coli AMK 171 0 0 0 0 171</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> E. coli AMP 196 0 0 196 0 392</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> E. coli AMX 196 0 0 196 0 392</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> E. coli AZM 0 0 0 467 0 467</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> E. coli CAZ 449 0 0 11 0 460</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> E. coli CHL 0 0 0 0 0 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> E. coli CIP 398 0 1 57 0 456</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> E. coli CLI 0 0 0 467 0 467</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> E. coli COL 240 0 0 0 0 240</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># 70 more rows</span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Use 'format()' on this result to get a publishable/printable format.</span>
<span class="r-in"><span><span class="co"># }</span></span></span>

View File

@ -16,7 +16,7 @@ Use as.sir() to transform MICs or disks measurements to SIR values."><meta prope
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -223,7 +223,7 @@ Use as.sir() to transform MICs or disks measurements to SIR values."><meta prope
<p>Like all data sets in this package, this data set is publicly available for download in the following formats: R, MS Excel, Apache Feather, Apache Parquet, SPSS, SAS, and Stata. Please visit <a href="https://msberends.github.io/AMR/articles/datasets.html">our website for the download links</a>. The actual files are of course available on <a href="https://github.com/msberends/AMR/tree/main/data-raw" class="external-link">our GitHub repository</a>. They allow for machine reading EUCAST and CLSI guidelines, which is almost impossible with the MS Excel and PDF files distributed by EUCAST and CLSI, though initiatives have started to overcome these burdens.</p>
<p><strong>NOTE:</strong> this <code>AMR</code> package (and the WHONET software as well) contains internal methods to apply the guidelines, which is rather complex. For example, some breakpoints must be applied on certain species groups (which are in case of this package available through the <a href="microorganisms.groups.html">microorganisms.groups</a> data set). It is important that this is considered when using the breakpoints for own use.</p>
<p><strong>NOTE:</strong> this <code>AMR</code> package (and the WHONET software as well) contains rather complex internal methods to apply the guidelines. For example, some breakpoints must be applied on certain species groups (which are in case of this package available through the <a href="microorganisms.groups.html">microorganisms.groups</a> data set). It is important that this is considered when using the breakpoints for own use.</p>
</div>
</div>

View File

@ -12,7 +12,7 @@ count_resistant() should be used to count resistant isolates, count_susceptible(
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -172,15 +172,15 @@ count_resistant() should be used to count resistant isolates, count_susceptible(
<span></span>
<span><span class="fu">count_susceptible</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_R</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_IR</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_I</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span><span class="fu">count_S</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_SI</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_S</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span><span class="fu">count_I</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_IR</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_R</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">count_all</span><span class="op">(</span><span class="va">...</span>, only_all_tested <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span>
<span></span>
@ -298,17 +298,21 @@ A microorganism is categorised as "Resistant" when there is a high likelihood of
<span class="r-in"><span><span class="co"># be more specific</span></span></span>
<span class="r-in"><span><span class="fu">count_S</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Using count_S() is discouraged; use count_susceptible() instead to also</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> consider "I" being susceptible. This note will be shown once for this</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> session.</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> consider "I" and "SDD" being susceptible. This note will be shown once for</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> this session.</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 543</span>
<span class="r-in"><span><span class="fu">count_SI</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Note that count_SI() will also count dose-dependent susceptibility,</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> 'SDD'. This note will be shown once for this session.</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 546</span>
<span class="r-in"><span><span class="fu">count_I</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Note that count_I() will also count dose-dependent susceptibility, 'SDD'.</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> This note will be shown once for this session.</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 3</span>
<span class="r-in"><span><span class="fu">count_IR</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Using count_IR() is discouraged; use count_resistant() instead to not</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> consider "I" being resistant. This note will be shown once for this</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> session.</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> consider "I" and "SDD" being resistant. This note will be shown once for</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> this session.</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 807</span>
<span class="r-in"><span><span class="fu">count_R</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 804</span>
@ -373,21 +377,27 @@ A microorganism is categorised as "Resistant" when there is a high likelihood of
<span class="r-in"><span><span class="op">}</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> For aminoglycosides() using columns 'GEN' (gentamicin), 'TOB'</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> (tobramycin), 'AMK' (amikacin), and 'KAN' (kanamycin)</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 12 × 4</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 18 × 4</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> ward antibiotic interpretation value</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">*</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;ord&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> Clinical AMX SI 357</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> Clinical AMX R 487</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Clinical CIP SI 741</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> Clinical CIP R 128</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> ICU AMX SI 158</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> ICU AMX R 270</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> ICU CIP SI 362</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> ICU CIP R 85</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> Outpatient AMX SI 31</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> Outpatient AMX R 47</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">11</span> Outpatient CIP SI 78</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">12</span> Outpatient CIP R 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Clinical AMX <span style="color: #BB0000;">NA</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> Clinical CIP SI 741</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> Clinical CIP R 128</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> Clinical CIP <span style="color: #BB0000;">NA</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> ICU AMX SI 158</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> ICU AMX R 270</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> ICU AMX <span style="color: #BB0000;">NA</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> ICU CIP SI 362</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">11</span> ICU CIP R 85</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">12</span> ICU CIP <span style="color: #BB0000;">NA</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">13</span> Outpatient AMX SI 31</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">14</span> Outpatient AMX R 47</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">15</span> Outpatient AMX <span style="color: #BB0000;">NA</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">16</span> Outpatient CIP SI 78</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">17</span> Outpatient CIP R 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">18</span> Outpatient CIP <span style="color: #BB0000;">NA</span> 0</span>
<span class="r-in"><span><span class="co"># }</span></span></span>
</code></pre></div>
</div>

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -12,7 +12,7 @@ To improve the interpretation of the antibiogram before EUCAST rules are applied
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -12,7 +12,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -234,8 +234,9 @@
<dt>stdres</dt>
<dd><p>standardized residuals,
<code>(observed - expected) / sqrt(V)</code>, where <code>V</code> is the residual cell variance (Agresti, 2007,
section 2.4.5 for the case where <code>x</code> is a matrix, <code>n * p * (1 - p)</code> otherwise).</p></dd>
<code>(observed - expected) / sqrt(V)</code>, where <code>V</code> is the
residual cell variance (Agresti, 2007, section 2.4.5
for the case where <code>x</code> is a matrix, <code>n * p * (1 - p)</code> otherwise).</p></dd>
</dl></div>
<div class="section level2">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 46 KiB

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

After

Width:  |  Height:  |  Size: 47 KiB

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -413,9 +413,9 @@
<span class="r-in"><span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/select.html" class="external-link">select</a></span><span class="op">(</span><span class="va">age_group</span>, <span class="va">CIP</span><span class="op">)</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span></span>
<span class="r-in"><span> <span class="fu">ggplot_sir</span><span class="op">(</span>x <span class="op">=</span> <span class="st">"age_group"</span><span class="op">)</span></span></span>
<span class="r-in"><span><span class="op">}</span></span></span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> <span class="warning">Warning: </span>Removed 6 rows containing missing values or values outside the scale range</span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> <span class="warning">Warning: </span>Removed 9 rows containing missing values or values outside the scale range</span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> (`geom_col()`).</span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> <span class="warning">Warning: </span>Removed 6 rows containing missing values or values outside the scale range</span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> <span class="warning">Warning: </span>Removed 9 rows containing missing values or values outside the scale range</span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> (`geom_text()`).</span>
<span class="r-plt img"><img src="ggplot_sir-8.png" alt="" width="700" height="433"></span>
<span class="r-in"><span><span class="kw">if</span> <span class="op">(</span><span class="kw"><a href="https://rdrr.io/r/base/library.html" class="external-link">require</a></span><span class="op">(</span><span class="st"><a href="https://ggplot2.tidyverse.org" class="external-link">"ggplot2"</a></span><span class="op">)</span> <span class="op">&amp;&amp;</span> <span class="kw"><a href="https://rdrr.io/r/base/library.html" class="external-link">require</a></span><span class="op">(</span><span class="st"><a href="https://dplyr.tidyverse.org" class="external-link">"dplyr"</a></span><span class="op">)</span><span class="op">)</span> <span class="op">{</span></span></span>

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -299,7 +299,7 @@
<dd>Calculate Antimicrobial Resistance</dd>
</dl><dl><dt>
<code><a href="count.html">count_resistant()</a></code> <code><a href="count.html">count_susceptible()</a></code> <code><a href="count.html">count_R()</a></code> <code><a href="count.html">count_IR()</a></code> <code><a href="count.html">count_I()</a></code> <code><a href="count.html">count_SI()</a></code> <code><a href="count.html">count_S()</a></code> <code><a href="count.html">count_all()</a></code> <code><a href="count.html">n_sir()</a></code> <code><a href="count.html">count_df()</a></code>
<code><a href="count.html">count_resistant()</a></code> <code><a href="count.html">count_susceptible()</a></code> <code><a href="count.html">count_S()</a></code> <code><a href="count.html">count_SI()</a></code> <code><a href="count.html">count_I()</a></code> <code><a href="count.html">count_IR()</a></code> <code><a href="count.html">count_R()</a></code> <code><a href="count.html">count_all()</a></code> <code><a href="count.html">n_sir()</a></code> <code><a href="count.html">count_df()</a></code>
</dt>
<dd>Count Available Isolates</dd>
</dl><dl><dt>

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -12,7 +12,7 @@ This is the fastest way to have your organisation (or analysis) specific codes p
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -213,7 +213,7 @@
standard deviations are less than or equal to <code>tol</code> times the
standard deviation of the first component.) With the default null
setting, no components are omitted (unless <code>rank.</code> is specified
less than <code>min(dim(x))</code>.). Other settings for tol could be
less than <code>min(dim(x))</code>.). Other settings for <code>tol</code> could be
<code>tol = 0</code> or <code>tol = sqrt(.Machine$double.eps)</code>, which
would omit essentially constant components.</p></dd>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 26 KiB

View File

@ -12,7 +12,7 @@ Especially the scale_*_mic() functions are relevant wrappers to plot MIC values
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -12,7 +12,7 @@ resistance() should be used to calculate resistance, susceptibility() should be
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
@ -277,7 +277,7 @@ resistance() should be used to calculate resistance, susceptibility() should be
<div class="section level2">
<h2 id="details">Details<a class="anchor" aria-label="anchor" href="#details"></a></h2>
<p><strong>Remember that you should filter your data to let it contain only first isolates!</strong> This is needed to exclude duplicates and to reduce selection bias. Use <code><a href="first_isolate.html">first_isolate()</a></code> to determine them in your data set with one of the four available algorithms.</p>
<p>The function <code>resistance()</code> is equal to the function <code>proportion_R()</code>. The function <code>susceptibility()</code> is equal to the function <code>proportion_SI()</code>.</p>
<p>The function <code>resistance()</code> is equal to the function <code>proportion_R()</code>. The function <code>susceptibility()</code> is equal to the function <code>proportion_SI()</code>. Since AMR v3.0, <code>proportion_SI()</code> and <code>proportion_I()</code> include dose-dependent susceptibility ('SDD').</p>
<p>Use <code>sir_confidence_interval()</code> to calculate the confidence interval, which relies on <code><a href="https://rdrr.io/r/stats/binom.test.html" class="external-link">binom.test()</a></code>, i.e., the Clopper-Pearson method. This function returns a vector of length 2 at default for antimicrobial <em>resistance</em>. Change the <code>side</code> argument to "left"/"min" or "right"/"max" to return a single value, and change the <code>ab_result</code> argument to e.g. <code>c("S", "I")</code> to test for antimicrobial <em>susceptibility</em>, see Examples.</p>
<p>These functions are not meant to count isolates, but to calculate the proportion of resistance/susceptibility. Use the <code><a href="count.html">count_*()</a></code> functions to count isolates. The function <code>susceptibility()</code> is essentially equal to <code><a href="count.html">count_susceptible()</a></code><code>/</code><code><a href="count.html">count_all()</a></code>. <em>Low counts can influence the outcome - the <code>proportion_*()</code> functions may camouflage this, since they only return the proportion (albeit dependent on the <code>minimum</code> argument).</em></p>
<p>The function <code>proportion_df()</code> takes any variable from <code>data</code> that has an <code><a href="as.sir.html">sir</a></code> class (created with <code><a href="as.sir.html">as.sir()</a></code>) and calculates the proportions S, I, and R. It also supports grouped variables. The function <code>sir_df()</code> works exactly like <code>proportion_df()</code>, but adds the number of isolates.</p>
@ -384,10 +384,16 @@ A microorganism is categorised as "Resistant" when there is a high likelihood of
<span class="r-in"><span><span class="fu">proportion_S</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.4022222</span>
<span class="r-in"><span><span class="fu">proportion_SI</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Note that proportion_SI() will also include dose-dependent</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> susceptibility, 'SDD'. This note will be shown once for this session.</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.4044444</span>
<span class="r-in"><span><span class="fu">proportion_I</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Note that proportion_I() will also include dose-dependent susceptibility,</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> 'SDD'. This note will be shown once for this session.</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.002222222</span>
<span class="r-in"><span><span class="fu">proportion_IR</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Note that proportion_IR() will also include dose-dependent</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> susceptibility, 'SDD'. This note will be shown once for this session.</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.5977778</span>
<span class="r-in"><span><span class="fu">proportion_R</span><span class="op">(</span><span class="va">example_isolates</span><span class="op">$</span><span class="va">AMX</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.5955556</span>
@ -511,21 +517,27 @@ A microorganism is categorised as "Resistant" when there is a high likelihood of
<span class="r-in"><span> <span class="fu"><a href="https://dplyr.tidyverse.org/reference/group_by.html" class="external-link">group_by</a></span><span class="op">(</span><span class="va">ward</span><span class="op">)</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span></span>
<span class="r-in"><span> <span class="fu">sir_df</span><span class="op">(</span>translate <span class="op">=</span> <span class="cn">FALSE</span><span class="op">)</span></span></span>
<span class="r-in"><span><span class="op">}</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 12 × 7</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 18 × 7</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> ward antibiotic interpretation value ci_min ci_max isolates</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">*</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;ord&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&gt;</span> <span style="color: #949494; font-style: italic;">&lt;int&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> Clinical AMX SI 0.423 0.389 0.457 357</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> Clinical AMX R 0.577 0.543 0.611 487</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Clinical CIP SI 0.853 0.827 0.876 741</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> Clinical CIP R 0.147 0.124 0.173 128</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> ICU AMX SI 0.369 0.323 0.417 158</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> ICU AMX R 0.631 0.583 0.677 270</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> ICU CIP SI 0.810 0.770 0.845 362</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> ICU CIP R 0.190 0.155 0.230 85</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> Outpatient AMX SI 0.397 0.288 0.515 31</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> Outpatient AMX R 0.603 0.485 0.712 47</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">11</span> Outpatient CIP SI 0.839 0.748 0.907 78</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">12</span> Outpatient CIP R 0.161 0.093<span style="text-decoration: underline;">2</span> 0.252 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Clinical AMX <span style="color: #BB0000;">NA</span> 0 0 0.004<span style="text-decoration: underline;">36</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> Clinical CIP SI 0.853 0.827 0.876 741</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> Clinical CIP R 0.147 0.124 0.173 128</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> Clinical CIP <span style="color: #BB0000;">NA</span> 0 0 0.004<span style="text-decoration: underline;">24</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> ICU AMX SI 0.369 0.323 0.417 158</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> ICU AMX R 0.631 0.583 0.677 270</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> ICU AMX <span style="color: #BB0000;">NA</span> 0 0 0.008<span style="text-decoration: underline;">58</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> ICU CIP SI 0.810 0.770 0.845 362</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">11</span> ICU CIP R 0.190 0.155 0.230 85</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">12</span> ICU CIP <span style="color: #BB0000;">NA</span> 0 0 0.008<span style="text-decoration: underline;">22</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">13</span> Outpatient AMX SI 0.397 0.288 0.515 31</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">14</span> Outpatient AMX R 0.603 0.485 0.712 47</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">15</span> Outpatient AMX <span style="color: #BB0000;">NA</span> 0 0 0.046<span style="text-decoration: underline;">2</span> 0</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">16</span> Outpatient CIP SI 0.839 0.748 0.907 78</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">17</span> Outpatient CIP R 0.161 0.093<span style="text-decoration: underline;">2</span> 0.252 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">18</span> Outpatient CIP <span style="color: #BB0000;">NA</span> 0 0 0.038<span style="text-decoration: underline;">9</span> 0</span>
<span class="r-in"><span><span class="co"># }</span></span></span>
</code></pre></div>
</div>

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -12,7 +12,7 @@ When negative ('left-skewed'): the left tail is longer; the mass of the distribu
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

View File

@ -10,7 +10,7 @@
<a class="navbar-brand me-2" href="../index.html">AMR (for R)</a>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9029</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">2.1.1.9031</small>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">

File diff suppressed because one or more lines are too long