1
0
mirror of https://github.com/msberends/AMR.git synced 2025-07-09 02:03:04 +02:00

Built site for AMR: 1.8.2.9049@496c08d

This commit is contained in:
github-actions
2022-11-13 07:54:32 +00:00
parent 6fd5ff2a24
commit bdc43910ae
98 changed files with 1928 additions and 2274 deletions

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

View File

@ -5,7 +5,7 @@ This work was published in the Journal of Statistical Software (Volume 104(3); d
) and formed the basis of two PhD theses (doi:10.33612/diss.177417131
and doi:10.33612/diss.192486375
).
After installing this package, R knows ~49,000 distinct microbial species and all ~580 antibiotic, antimycotic and antiviral drugs by name and code (including ATC, EARS-NET, LOINC and SNOMED CT), and knows all about valid R/SI and MIC values. It supports any data format, including WHONET/EARS-Net data.
After installing this package, R knows ~49,000 distinct microbial species and all ~600 antibiotic, antimycotic and antiviral drugs by name and code (including ATC, EARS-NET, LOINC and SNOMED CT), and knows all about valid R/SI and MIC values. It supports any data format, including WHONET/EARS-Net data.
This package is fully independent of any other R package and works on Windows, macOS and Linux with all versions of R since R-3.0.0 (April 2013). It was designed to work in any setting, including those with very limited resources. It was created for both routine data analysis and academic research at the Faculty of Medical Sciences of the University of Groningen, in collaboration with non-profit organisations Certe Medical Diagnostics and Advice and University Medical Center Groningen. This R package is actively maintained and free software; you can freely use and distribute it for both personal and commercial (but not patent) purposes under the terms of the GNU General Public License version 2.0 (GPL-2), as published by the Free Software Foundation.
This package can be used for:
Reference for the taxonomy of microorganisms, since the package contains all microbial (sub)species from the List of Prokaryotic names with Standing in Nomenclature (LPSN) and the Global Biodiversity Information Facility (GBIF)
@ -31,7 +31,7 @@ This work was published in the Journal of Statistical Software (Volume 104(3); d
) and formed the basis of two PhD theses (doi:10.33612/diss.177417131
and doi:10.33612/diss.192486375
).
After installing this package, R knows ~49,000 distinct microbial species and all ~580 antibiotic, antimycotic and antiviral drugs by name and code (including ATC, EARS-NET, LOINC and SNOMED CT), and knows all about valid R/SI and MIC values. It supports any data format, including WHONET/EARS-Net data.
After installing this package, R knows ~49,000 distinct microbial species and all ~600 antibiotic, antimycotic and antiviral drugs by name and code (including ATC, EARS-NET, LOINC and SNOMED CT), and knows all about valid R/SI and MIC values. It supports any data format, including WHONET/EARS-Net data.
This package is fully independent of any other R package and works on Windows, macOS and Linux with all versions of R since R-3.0.0 (April 2013). It was designed to work in any setting, including those with very limited resources. It was created for both routine data analysis and academic research at the Faculty of Medical Sciences of the University of Groningen, in collaboration with non-profit organisations Certe Medical Diagnostics and Advice and University Medical Center Groningen. This R package is actively maintained and free software; you can freely use and distribute it for both personal and commercial (but not patent) purposes under the terms of the GNU General Public License version 2.0 (GPL-2), as published by the Free Software Foundation.
This package can be used for:
Reference for the taxonomy of microorganisms, since the package contains all microbial (sub)species from the List of Prokaryotic names with Standing in Nomenclature (LPSN) and the Global Biodiversity Information Facility (GBIF)
@ -62,7 +62,7 @@ Principal component analysis for AMR
<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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -134,6 +134,11 @@ Principal component analysis for AMR
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -186,7 +191,7 @@ Principal component analysis for AMR
) and formed the basis of two PhD theses (<a href="https://doi.org/10.33612/diss.177417131" class="external-link">doi:10.33612/diss.177417131</a>
and <a href="https://doi.org/10.33612/diss.192486375" class="external-link">doi:10.33612/diss.192486375</a>
).</p>
<p>After installing this package, <span style="R">R</span> knows ~49,000 distinct microbial species and all ~580 antibiotic, antimycotic and antiviral drugs by name and code (including ATC, EARS-NET, LOINC and SNOMED CT), and knows all about valid R/SI and MIC values. It supports any data format, including WHONET/EARS-Net data.</p>
<p>After installing this package, <span style="R">R</span> knows ~49,000 distinct microbial species and all ~600 antibiotic, antimycotic and antiviral drugs by name and code (including ATC, EARS-NET, LOINC and SNOMED CT), and knows all about valid R/SI and MIC values. It supports any data format, including WHONET/EARS-Net data.</p>
<p>This package is fully independent of any other <span style="R">R</span> package and works on Windows, macOS and Linux with all versions of <span style="R">R</span> since R-3.0.0 (April 2013). It was designed to work in any setting, including those with very limited resources. It was created for both routine data analysis and academic research at the Faculty of Medical Sciences of the University of Groningen, in collaboration with non-profit organisations Certe Medical Diagnostics and Advice and University Medical Center Groningen. This <span style="R">R</span> package is actively maintained and free software; you can freely use and distribute it for both personal and commercial (but not patent) purposes under the terms of the GNU General Public License version 2.0 (GPL-2), as published by the Free Software Foundation.</p>
<p>This package can be used for:</p><ul><li><p>Reference for the taxonomy of microorganisms, since the package contains all microbial (sub)species from the List of Prokaryotic names with Standing in Nomenclature (LPSN) and the Global Biodiversity Information Facility (GBIF)</p></li>
<li><p>Interpreting raw MIC and disk diffusion values, based on any CLSI or EUCAST guideline from the last 10 years</p></li>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.2 KiB

After

Width:  |  Height:  |  Size: 9.1 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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -208,7 +213,7 @@
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="co"># mind the bad spelling of amoxicillin in this line,</span></span></span>
<span class="r-in"><span><span class="co"># straight from a true health care record:</span></span></span>
<span class="r-in"><span><span class="fu">ab_from_text</span><span class="op">(</span><span class="st">"28/03/2020 regular amoxicilliin 500mg po tds"</span><span class="op">)</span></span></span>
<span class="r-in"><span><span class="fu">ab_from_text</span><span class="op">(</span><span class="st">"28/03/2020 regular amoxicilliin 500mg po tid"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [[1]]</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'ab'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] AMX</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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="nav-item">
@ -249,13 +254,13 @@
<div class="section level2">
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="co"># all properties:</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># "Amoxicillin"</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Amoxicillin"</span>
<span class="r-in"><span><span class="fu">ab_atc</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># "J01CA04" (ATC code from the WHO)</span></span></span>
<span class="r-in"><span><span class="fu">ab_atc</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "J01CA04"</span>
<span class="r-in"><span><span class="fu">ab_cid</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># 33613 (Compound ID from PubChem)</span></span></span>
<span class="r-in"><span><span class="fu">ab_cid</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 33613</span>
<span class="r-in"><span><span class="fu">ab_synonyms</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># a list with brand names of amoxicillin</span></span></span>
<span class="r-in"><span><span class="fu">ab_synonyms</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "actimoxi" "amoclen" "amolin" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [4] "amopen" "amopenixin" "amoxibiotic" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] "amoxicaps" "amoxicilina" "amoxicillin" </span>
@ -275,7 +280,7 @@
<span class="r-out co"><span class="r-pr">#&gt;</span> [49] "robamox" "sawamox pm" "tolodina" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [52] "topramoxin" "unicillin" "utimox" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [55] "vetramox" </span>
<span class="r-in"><span><span class="fu">ab_tradenames</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># same</span></span></span>
<span class="r-in"><span><span class="fu">ab_tradenames</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "actimoxi" "amoclen" "amolin" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [4] "amopen" "amopenixin" "amoxibiotic" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] "amoxicaps" "amoxicilina" "amoxicillin" </span>
@ -295,33 +300,30 @@
<span class="r-out co"><span class="r-pr">#&gt;</span> [49] "robamox" "sawamox pm" "tolodina" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [52] "topramoxin" "unicillin" "utimox" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [55] "vetramox" </span>
<span class="r-in"><span><span class="fu">ab_group</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># "Beta-lactams/penicillins"</span></span></span>
<span class="r-in"><span><span class="fu">ab_group</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Beta-lactams/penicillins"</span>
<span class="r-in"><span><span class="fu">ab_atc_group1</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># "Beta-lactam antibacterials, penicillins"</span></span></span>
<span class="r-in"><span><span class="fu">ab_atc_group1</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Beta-lactam antibacterials, penicillins"</span>
<span class="r-in"><span><span class="fu">ab_atc_group2</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># "Penicillins with extended spectrum"</span></span></span>
<span class="r-in"><span><span class="fu">ab_atc_group2</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Penicillins with extended spectrum"</span>
<span class="r-in"><span><span class="fu">ab_url</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># link to the official WHO page</span></span></span>
<span class="r-in"><span><span class="fu">ab_url</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Amoxicillin </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> "https://www.whocc.no/atc_ddd_index/?code=J01CA04&amp;showdescription=no" </span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># smart lowercase tranformation</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span>x <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">"PLB"</span><span class="op">)</span><span class="op">)</span> <span class="co"># "Amoxicillin/clavulanic acid" "Polymyxin B"</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span>x <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">"PLB"</span><span class="op">)</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Amoxicillin/clavulanic acid" "Polymyxin B" </span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span></span></span>
<span class="r-in"><span> x <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">"PLB"</span><span class="op">)</span>,</span></span>
<span class="r-in"><span> tolower <span class="op">=</span> <span class="cn">TRUE</span></span></span>
<span class="r-in"><span><span class="op">)</span> <span class="co"># "amoxicillin/clavulanic acid" "polymyxin B"</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span>x <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">"PLB"</span><span class="op">)</span>, tolower <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "amoxicillin/clavulanic acid" "polymyxin B" </span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># defined daily doses (DDD)</span></span></span>
<span class="r-in"><span><span class="fu">ab_ddd</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"oral"</span><span class="op">)</span> <span class="co"># 1.5</span></span></span>
<span class="r-in"><span><span class="fu">ab_ddd</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"oral"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 1.5</span>
<span class="r-in"><span><span class="fu">ab_ddd_units</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"oral"</span><span class="op">)</span> <span class="co"># "g"</span></span></span>
<span class="r-in"><span><span class="fu">ab_ddd_units</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"oral"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "g"</span>
<span class="r-in"><span><span class="fu">ab_ddd</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"iv"</span><span class="op">)</span> <span class="co"># 3</span></span></span>
<span class="r-in"><span><span class="fu">ab_ddd</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"iv"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 3</span>
<span class="r-in"><span><span class="fu">ab_ddd_units</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"iv"</span><span class="op">)</span> <span class="co"># "g"</span></span></span>
<span class="r-in"><span><span class="fu">ab_ddd_units</span><span class="op">(</span><span class="st">"AMX"</span>, <span class="st">"iv"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "g"</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu">ab_info</span><span class="op">(</span><span class="st">"AMX"</span><span class="op">)</span> <span class="co"># all properties as a list</span></span></span>
@ -390,17 +392,17 @@
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># all ab_* functions use as.ab() internally, so you can go from 'any' to 'any':</span></span></span>
<span class="r-in"><span><span class="fu">ab_atc</span><span class="op">(</span><span class="st">"AMP"</span><span class="op">)</span> <span class="co"># ATC code of AMP (ampicillin)</span></span></span>
<span class="r-in"><span><span class="fu">ab_atc</span><span class="op">(</span><span class="st">"AMP"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "J01CA01" "S01AA19"</span>
<span class="r-in"><span><span class="fu">ab_group</span><span class="op">(</span><span class="st">"J01CA01"</span><span class="op">)</span> <span class="co"># Drug group of ampicillins ATC code</span></span></span>
<span class="r-in"><span><span class="fu">ab_group</span><span class="op">(</span><span class="st">"J01CA01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Beta-lactams/penicillins"</span>
<span class="r-in"><span><span class="fu">ab_loinc</span><span class="op">(</span><span class="st">"ampicillin"</span><span class="op">)</span> <span class="co"># LOINC codes of ampicillin</span></span></span>
<span class="r-in"><span><span class="fu">ab_loinc</span><span class="op">(</span><span class="st">"ampicillin"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "21066-6" "3355-5" "33562-0" "33919-2" "43883-8" "43884-6" "87604-5"</span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="st">"21066-6"</span><span class="op">)</span> <span class="co"># "Ampicillin" (using LOINC)</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="st">"21066-6"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Ampicillin"</span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="fl">6249</span><span class="op">)</span> <span class="co"># "Ampicillin" (using CID)</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="fl">6249</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Ampicillin"</span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="st">"J01CA01"</span><span class="op">)</span> <span class="co"># "Ampicillin" (using ATC)</span></span></span>
<span class="r-in"><span><span class="fu">ab_name</span><span class="op">(</span><span class="st">"J01CA01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Ampicillin"</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># spelling from different languages and dyslexia are no problem</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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -190,16 +195,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 1953-11-27 68 68.95890 46</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 1960-04-11 62 62.58904 39</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 1973-06-04 49 49.44110 26</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 1977-12-02 44 44.94521 22</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 1970-05-13 52 52.50137 29</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 1976-05-14 46 46.49863 23</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 1962-08-03 60 60.27671 37</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 1939-08-15 83 83.24384 60</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 1984-10-15 38 38.07671 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 1932-12-30 89 89.86849 67</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 1984-10-18 38 38.07123 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 1943-11-13 79 79.00000 56</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 1931-12-13 90 90.91781 68</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 1962-05-06 60 60.52329 37</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 1976-02-14 46 46.74521 23</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 1992-06-07 30 30.43562 7</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 1988-06-21 34 34.39726 11</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 1962-04-24 60 60.55616 37</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 1963-06-24 59 59.38904 36</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 1994-03-22 28 28.64658 5</span>
</code></pre></div>
</div>
</main><aside class="col-md-3"><nav id="toc"><h2>On this page</h2>

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

File diff suppressed because one or more lines are too long

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -254,9 +259,9 @@ This package contains <strong>all ~550 antibiotic, antimycotic and antiviral dru
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># use ab_* functions to get a specific properties (see ?ab_property);</span></span></span>
<span class="r-in"><span><span class="co"># they use as.ab() internally:</span></span></span>
<span class="r-in"><span><span class="fu"><a href="ab_property.html">ab_name</a></span><span class="op">(</span><span class="st">"J01FA01"</span><span class="op">)</span> <span class="co"># "Erythromycin"</span></span></span>
<span class="r-in"><span><span class="fu"><a href="ab_property.html">ab_name</a></span><span class="op">(</span><span class="st">"J01FA01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Erythromycin"</span>
<span class="r-in"><span><span class="fu"><a href="ab_property.html">ab_name</a></span><span class="op">(</span><span class="st">"eryt"</span><span class="op">)</span> <span class="co"># "Erythromycin"</span></span></span>
<span class="r-in"><span><span class="fu"><a href="ab_property.html">ab_name</a></span><span class="op">(</span><span class="st">"eryt"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Erythromycin"</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># \donttest{</span></span></span>

277
reference/as.av.html Normal file
View File

@ -0,0 +1,277 @@
<!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="Use this function to determine the antiviral agent code of one or more antiviral agents. The data set antivirals will be searched for abbreviations, official names and synonyms (brand names)."><title>Transform Input to an Antiviral Agent ID — as.av • 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.1.3/bootstrap.min.css" rel="stylesheet"><script src="../deps/bootstrap-5.1.3/bootstrap.bundle.min.js"></script><link href="../deps/Fira_Code-0.4.2/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.rawgit.com/afeld/bootstrap-toc/v1.0.1/dist/bootstrap-toc.min.js"></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.6/clipboard.min.js" integrity="sha256-inc5kl9MA1hkeYUt+EC3BhlIgyp/2jDIyBLS6k3UxPI=" crossorigin="anonymous"></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="Transform Input to an Antiviral Agent ID — as.av"><meta property="og:description" content="Use this function to determine the antiviral agent code of one or more antiviral agents. The data set antivirals will be searched for abbreviations, official names and synonyms (brand names)."><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>
<a href="#main" class="visually-hidden-focusable">Skip to contents</a>
<nav class="navbar fixed-top navbar-dark navbar-expand-lg bg-primary"><div class="container">
<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="">1.8.2.9049</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">
<span class="navbar-toggler-icon"></span>
</button>
<div id="navbar" class="collapse navbar-collapse ms-3">
<ul class="navbar-nav me-auto"><li class="nav-item">
<a class="nav-link" href="../index.html">
<span class="fa fa-home"></span>
Home
</a>
</li>
<li class="nav-item dropdown">
<a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown" role="button" aria-expanded="false" aria-haspopup="true" id="dropdown--how-to">
<span class="fa fa-question-circle"></span>
How to
</a>
<div class="dropdown-menu" aria-labelledby="dropdown--how-to">
<a class="dropdown-item" href="../articles/AMR.html">
<span class="fa fa-directions"></span>
Conduct AMR analysis
</a>
<a class="dropdown-item" href="../articles/resistance_predict.html">
<span class="fa fa-dice"></span>
Predict antimicrobial resistance
</a>
<a class="dropdown-item" href="../articles/datasets.html">
<span class="fa fa-database"></span>
Data sets for download / own use
</a>
<a class="dropdown-item" href="../articles/PCA.html">
<span class="fa fa-compress"></span>
Conduct principal component analysis for AMR
</a>
<a class="dropdown-item" href="../articles/MDR.html">
<span class="fa fa-skull-crossbones"></span>
Determine multi-drug resistance (MDR)
</a>
<a class="dropdown-item" href="../articles/WHONET.html">
<span class="fa fa-globe-americas"></span>
Work with WHONET data
</a>
<a class="dropdown-item" href="../articles/SPSS.html">
<span class="fa fa-file-upload"></span>
Import data from SPSS/SAS/Stata
</a>
<a class="dropdown-item" href="../articles/EUCAST.html">
<span class="fa fa-exchange-alt"></span>
Apply EUCAST rules
</a>
<a class="dropdown-item" href="../reference/mo_property.html">
<span class="fa fa-bug"></span>
Get properties of a microorganism
</a>
<a class="dropdown-item" href="../reference/ab_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
<a class="nav-link" href="../reference/index.html">
<span class="fa fa-book-open"></span>
Manual
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="../authors.html">
<span class="fa fa-users"></span>
Authors
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="../news/index.html">
<span class="far fa far fa-newspaper"></span>
Changelog
</a>
</li>
</ul><form class="form-inline my-2 my-lg-0" role="search">
<input type="search" class="form-control me-sm-2" aria-label="Toggle navigation" name="search-input" data-search-index="../search.json" id="search-input" placeholder="Search for" autocomplete="off"></form>
<ul class="navbar-nav"><li class="nav-item">
<a class="external-link nav-link" href="https://github.com/msberends/AMR">
<span class="fab fa fab fa-github"></span>
Source Code
</a>
</li>
</ul></div>
</div>
</nav><div class="container template-reference-topic">
<div class="row">
<main id="main" class="col-md-9"><div class="page-header">
<img src="../logo.svg" class="logo" alt=""><h1>Transform Input to an Antiviral Agent ID</h1>
<small class="dont-index">Source: <a href="https://github.com/msberends/AMR/blob/HEAD/R/av.R" class="external-link"><code>R/av.R</code></a></small>
<div class="d-none name"><code>as.av.Rd</code></div>
</div>
<div class="ref-description section level2">
<p>Use this function to determine the antiviral agent code of one or more antiviral agents. The data set <a href="antibiotics.html">antivirals</a> will be searched for abbreviations, official names and synonyms (brand names).</p>
</div>
<div class="section level2">
<h2 id="ref-usage">Usage<a class="anchor" aria-label="anchor" href="#ref-usage"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span><span class="fu">as.av</span><span class="op">(</span><span class="va">x</span>, flag_multiple_results <span class="op">=</span> <span class="cn">TRUE</span>, info <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/interactive.html" class="external-link">interactive</a></span><span class="op">(</span><span class="op">)</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">is.av</span><span class="op">(</span><span class="va">x</span><span class="op">)</span></span></code></pre></div>
</div>
<div class="section level2">
<h2 id="arguments">Arguments<a class="anchor" aria-label="anchor" href="#arguments"></a></h2>
<dl><dt>x</dt>
<dd><p>a <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a> vector to determine to antiviral agent ID</p></dd>
<dt>flag_multiple_results</dt>
<dd><p>a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> to indicate whether a note should be printed to the console that probably more than one antiviral agent code or name can be retrieved from a single input value.</p></dd>
<dt>info</dt>
<dd><p>a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> to indicate whether a progress bar should be printed, defaults to <code>TRUE</code> only in interactive mode</p></dd>
<dt>...</dt>
<dd><p>arguments passed on to internal functions</p></dd>
</dl></div>
<div class="section level2">
<h2 id="value">Value<a class="anchor" aria-label="anchor" href="#value"></a></h2>
<p>A <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a></p>
<p></p>
<p><a href="https://rdrr.io/r/base/vector.html" class="external-link">vector</a> with additional class <code><a href="as.ab.html">ab</a></code></p>
</div>
<div class="section level2">
<h2 id="details">Details<a class="anchor" aria-label="anchor" href="#details"></a></h2>
<p>All entries in the <a href="antibiotics.html">antivirals</a> data set have three different identifiers: a human readable EARS-Net code (column <code>ab</code>, used by ECDC and WHONET), an ATC code (column <code>atc</code>, used by WHO), and a CID code (column <code>cid</code>, Compound ID, used by PubChem). The data set contains more than 5,000 official brand names from many different countries, as found in PubChem. Not that some drugs contain multiple ATC codes.</p>
<p>All these properties will be searched for the user input. The <code>as.av()</code> can correct for different forms of misspelling:</p><ul><li><p>Wrong spelling of drug names (such as "acyclovir"), which corrects for most audible similarities such as f/ph, x/ks, c/z/s, t/th, etc.</p></li>
<li><p>Too few or too many vowels or consonants</p></li>
<li><p>Switching two characters (such as "aycclovir", often the case in clinical data, when doctors typed too fast)</p></li>
<li><p>Digitalised paper records, leaving artefacts like 0/o/O (zero and O's), B/8, n/r, etc.</p></li>
</ul><p>Use the <code><a href="av_property.html">av_*</a></code> functions to get properties based on the returned antiviral agent ID, see <em>Examples</em>.</p>
<p>Note: the <code>as.av()</code> and <code><a href="av_property.html">av_*</a></code> functions may use very long regular expression to match brand names of antimicrobial agents. This may fail on some systems.</p>
</div>
<div class="section level2">
<h2 id="source">Source<a class="anchor" aria-label="anchor" href="#source"></a></h2>
<p>World Health Organization (WHO) Collaborating Centre for Drug Statistics Methodology: <a href="https://www.whocc.no/atc_ddd_index/" class="external-link">https://www.whocc.no/atc_ddd_index/</a></p>
<p>European Commission Public Health PHARMACEUTICALS - COMMUNITY REGISTER: <a href="https://ec.europa.eu/health/documents/community-register/html/reg_hum_atc.htm" class="external-link">https://ec.europa.eu/health/documents/community-register/html/reg_hum_atc.htm</a></p>
</div>
<div class="section level2">
<h2 id="whocc">WHOCC<a class="anchor" aria-label="anchor" href="#whocc"></a></h2>
<p><img src="figures/logo_who.png" height="60" style='margin-bottom:"5"'><br>
This package contains <strong>all ~550 antibiotic, antimycotic and antiviral drugs</strong> and their Anatomical Therapeutic Chemical (ATC) codes, ATC groups and Defined Daily Dose (DDD) from the World Health Organization Collaborating Centre for Drug Statistics Methodology (WHOCC, <a href="https://www.whocc.no" class="external-link">https://www.whocc.no</a>) and the Pharmaceuticals Community Register of the European Commission (<a href="https://ec.europa.eu/health/documents/community-register/html/reg_hum_atc.htm" class="external-link">https://ec.europa.eu/health/documents/community-register/html/reg_hum_atc.htm</a>).</p>
<p>These have become the gold standard for international drug utilisation monitoring and research.</p>
<p>The WHOCC is located in Oslo at the Norwegian Institute of Public Health and funded by the Norwegian government. The European Commission is the executive of the European Union and promotes its general interest.</p>
<p><strong>NOTE: The WHOCC copyright does not allow use for commercial purposes, unlike any other info from this package.</strong> See <a href="https://www.whocc.no/copyright_disclaimer/." class="external-link">https://www.whocc.no/copyright_disclaimer/.</a></p>
</div>
<div class="section level2">
<h2 id="reference-data-publicly-available">Reference Data Publicly Available<a class="anchor" aria-label="anchor" href="#reference-data-publicly-available"></a></h2>
<p>All data sets in this <code>AMR</code> package (about microorganisms, antibiotics, R/SI interpretation, EUCAST rules, etc.) are publicly and freely available for download in the following formats: R, MS Excel, Apache Feather, Apache Parquet, SPSS, SAS, and Stata. We also provide tab-separated plain text files that are machine-readable and suitable for input in any software program, such as laboratory information systems. 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>.</p>
</div>
<div class="section level2">
<h2 id="see-also">See also<a class="anchor" aria-label="anchor" href="#see-also"></a></h2>
<div class="dont-index">
<ul><li><p><a href="antibiotics.html">antivirals</a> for the <a href="https://rdrr.io/r/base/data.frame.html" class="external-link">data.frame</a> that is being used to determine ATCs</p></li>
<li><p><code><a href="av_from_text.html">av_from_text()</a></code> for a function to retrieve antimicrobial drugs from clinical text (from health care records)</p></li>
</ul></div>
</div>
<div class="section level2">
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="co"># these examples all return "ACI", the ID of aciclovir:</span></span></span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"J05AB01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"J 05 AB 01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"Aciclovir"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"aciclo"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">" aciclo 123"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"ACICL"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"Virorax"</span><span class="op">)</span> <span class="co"># trade name</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"Zovirax"</span><span class="op">)</span> <span class="co"># trade name</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu">as.av</span><span class="op">(</span><span class="st">"acyklofir"</span><span class="op">)</span> <span class="co"># severe spelling error, yet works</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ACI</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># use av_* functions to get a specific properties (see ?av_property);</span></span></span>
<span class="r-in"><span><span class="co"># they use as.av() internally:</span></span></span>
<span class="r-in"><span><span class="fu"><a href="av_property.html">av_name</a></span><span class="op">(</span><span class="st">"J05AB01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Aciclovir"</span>
<span class="r-in"><span><span class="fu"><a href="av_property.html">av_name</a></span><span class="op">(</span><span class="st">"acicl"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Aciclovir"</span>
</code></pre></div>
</div>
</main><aside class="col-md-3"><nav id="toc"><h2>On this page</h2>
</nav></aside></div>
<footer><div class="pkgdown-footer-left">
<p></p><p><code>AMR</code> (for R). Developed at the <a target="_blank" href="https://www.rug.nl" class="external-link">University of Groningen</a> in collaboration with non-profit organisations<br><a target="_blank" href="https://www.certe.nl" class="external-link">Certe Medical Diagnostics and Advice Foundation</a> and <a target="_blank" href="https://www.umcg.nl" class="external-link">University Medical Center Groningen</a>.</p>
</div>
<div class="pkgdown-footer-right">
<p></p><p><a target="_blank" href="https://www.rug.nl" class="external-link"><img src="https://github.com/msberends/AMR/raw/main/pkgdown/logos/logo_rug.svg" style="max-width: 150px;"></a></p>
</div>
</footer></div>
</body></html>

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -496,16 +501,16 @@ A microorganism is categorised as <em>Susceptible, Increased exposure</em> when
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 50 × 13</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> datetime index ab_input ab_consid…¹ mo_in…² mo_conside…³ guide…⁴</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;ab&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;mo&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> 2022-11-12 <span style="color: #949494;">11:14:27</span> 1 ampicillin AMP Strep … B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 2022-11-12 <span style="color: #949494;">11:14:27</span> 1 AMP AMP Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 2022-11-12 <span style="color: #949494;">11:14:28</span> 1 CIP CIP Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> 2022-11-12 <span style="color: #949494;">11:14:28</span> 1 GEN GEN Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 2022-11-12 <span style="color: #949494;">11:14:28</span> 1 TOB TOB Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 2022-11-12 <span style="color: #949494;">11:14:29</span> 1 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 2022-11-12 <span style="color: #949494;">11:14:29</span> 1 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 2022-11-12 <span style="color: #949494;">11:14:29</span> 2 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> 2022-11-12 <span style="color: #949494;">11:14:30</span> 3 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 2022-11-12 <span style="color: #949494;">11:14:30</span> 4 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> 2022-11-13 <span style="color: #949494;">07:51:04</span> 1 ampicillin AMP Strep … B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 2022-11-13 <span style="color: #949494;">07:51:05</span> 1 AMP AMP Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 2022-11-13 <span style="color: #949494;">07:51:05</span> 1 CIP CIP Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> 2022-11-13 <span style="color: #949494;">07:51:06</span> 1 GEN GEN Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 2022-11-13 <span style="color: #949494;">07:51:06</span> 1 TOB TOB Escher… B_ESCHR_COLI EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 2022-11-13 <span style="color: #949494;">07:51:07</span> 1 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 2022-11-13 <span style="color: #949494;">07:51:07</span> 1 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 2022-11-13 <span style="color: #949494;">07:51:07</span> 2 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> 2022-11-13 <span style="color: #949494;">07:51:08</span> 3 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 2022-11-13 <span style="color: #949494;">07:51:08</span> 4 AMX AMX B_STRP… B_STRPT_PNMN EUCAST…</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># … with 40 more rows, 6 more variables: ref_table &lt;chr&gt;, method &lt;chr&gt;,</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># breakpoint_S &lt;dbl&gt;, breakpoint_R &lt;dbl&gt;, input &lt;dbl&gt;, interpretation &lt;rsi&gt;,</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># and abbreviated variable names ¹ab_considered, ²mo_input, ³mo_considered,</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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

244
reference/av_from_text.html Normal file
View File

@ -0,0 +1,244 @@
<!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="Use this function on e.g. clinical texts from health care records. It returns a list with all antiviral drugs, doses and forms of administration found in the texts."><title>Retrieve Antiviral Drug Names and Doses from Clinical Text — av_from_text • 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.1.3/bootstrap.min.css" rel="stylesheet"><script src="../deps/bootstrap-5.1.3/bootstrap.bundle.min.js"></script><link href="../deps/Fira_Code-0.4.2/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.rawgit.com/afeld/bootstrap-toc/v1.0.1/dist/bootstrap-toc.min.js"></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.6/clipboard.min.js" integrity="sha256-inc5kl9MA1hkeYUt+EC3BhlIgyp/2jDIyBLS6k3UxPI=" crossorigin="anonymous"></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="Retrieve Antiviral Drug Names and Doses from Clinical Text — av_from_text"><meta property="og:description" content="Use this function on e.g. clinical texts from health care records. It returns a list with all antiviral drugs, doses and forms of administration found in the texts."><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>
<a href="#main" class="visually-hidden-focusable">Skip to contents</a>
<nav class="navbar fixed-top navbar-dark navbar-expand-lg bg-primary"><div class="container">
<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="">1.8.2.9049</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">
<span class="navbar-toggler-icon"></span>
</button>
<div id="navbar" class="collapse navbar-collapse ms-3">
<ul class="navbar-nav me-auto"><li class="nav-item">
<a class="nav-link" href="../index.html">
<span class="fa fa-home"></span>
Home
</a>
</li>
<li class="nav-item dropdown">
<a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown" role="button" aria-expanded="false" aria-haspopup="true" id="dropdown--how-to">
<span class="fa fa-question-circle"></span>
How to
</a>
<div class="dropdown-menu" aria-labelledby="dropdown--how-to">
<a class="dropdown-item" href="../articles/AMR.html">
<span class="fa fa-directions"></span>
Conduct AMR analysis
</a>
<a class="dropdown-item" href="../articles/resistance_predict.html">
<span class="fa fa-dice"></span>
Predict antimicrobial resistance
</a>
<a class="dropdown-item" href="../articles/datasets.html">
<span class="fa fa-database"></span>
Data sets for download / own use
</a>
<a class="dropdown-item" href="../articles/PCA.html">
<span class="fa fa-compress"></span>
Conduct principal component analysis for AMR
</a>
<a class="dropdown-item" href="../articles/MDR.html">
<span class="fa fa-skull-crossbones"></span>
Determine multi-drug resistance (MDR)
</a>
<a class="dropdown-item" href="../articles/WHONET.html">
<span class="fa fa-globe-americas"></span>
Work with WHONET data
</a>
<a class="dropdown-item" href="../articles/SPSS.html">
<span class="fa fa-file-upload"></span>
Import data from SPSS/SAS/Stata
</a>
<a class="dropdown-item" href="../articles/EUCAST.html">
<span class="fa fa-exchange-alt"></span>
Apply EUCAST rules
</a>
<a class="dropdown-item" href="../reference/mo_property.html">
<span class="fa fa-bug"></span>
Get properties of a microorganism
</a>
<a class="dropdown-item" href="../reference/ab_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
<a class="nav-link" href="../reference/index.html">
<span class="fa fa-book-open"></span>
Manual
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="../authors.html">
<span class="fa fa-users"></span>
Authors
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="../news/index.html">
<span class="far fa far fa-newspaper"></span>
Changelog
</a>
</li>
</ul><form class="form-inline my-2 my-lg-0" role="search">
<input type="search" class="form-control me-sm-2" aria-label="Toggle navigation" name="search-input" data-search-index="../search.json" id="search-input" placeholder="Search for" autocomplete="off"></form>
<ul class="navbar-nav"><li class="nav-item">
<a class="external-link nav-link" href="https://github.com/msberends/AMR">
<span class="fab fa fab fa-github"></span>
Source Code
</a>
</li>
</ul></div>
</div>
</nav><div class="container template-reference-topic">
<div class="row">
<main id="main" class="col-md-9"><div class="page-header">
<img src="../logo.svg" class="logo" alt=""><h1>Retrieve Antiviral Drug Names and Doses from Clinical Text</h1>
<small class="dont-index">Source: <a href="https://github.com/msberends/AMR/blob/HEAD/R/av_from_text.R" class="external-link"><code>R/av_from_text.R</code></a></small>
<div class="d-none name"><code>av_from_text.Rd</code></div>
</div>
<div class="ref-description section level2">
<p>Use this function on e.g. clinical texts from health care records. It returns a <a href="https://rdrr.io/r/base/list.html" class="external-link">list</a> with all antiviral drugs, doses and forms of administration found in the texts.</p>
</div>
<div class="section level2">
<h2 id="ref-usage">Usage<a class="anchor" aria-label="anchor" href="#ref-usage"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span><span class="fu">av_from_text</span><span class="op">(</span></span>
<span> <span class="va">text</span>,</span>
<span> type <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">"drug"</span>, <span class="st">"dose"</span>, <span class="st">"administration"</span><span class="op">)</span>,</span>
<span> collapse <span class="op">=</span> <span class="cn">NULL</span>,</span>
<span> translate_av <span class="op">=</span> <span class="cn">FALSE</span>,</span>
<span> thorough_search <span class="op">=</span> <span class="cn">NULL</span>,</span>
<span> info <span class="op">=</span> <span class="fu"><a href="https://rdrr.io/r/base/interactive.html" class="external-link">interactive</a></span><span class="op">(</span><span class="op">)</span>,</span>
<span> <span class="va">...</span></span>
<span><span class="op">)</span></span></code></pre></div>
</div>
<div class="section level2">
<h2 id="arguments">Arguments<a class="anchor" aria-label="anchor" href="#arguments"></a></h2>
<dl><dt>text</dt>
<dd><p>text to analyse</p></dd>
<dt>type</dt>
<dd><p>type of property to search for, either <code>"drug"</code>, <code>"dose"</code> or <code>"administration"</code>, see <em>Examples</em></p></dd>
<dt>collapse</dt>
<dd><p>a <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a> to pass on to <code>paste(, collapse = ...)</code> to only return one <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a> per element of <code>text</code>, see <em>Examples</em></p></dd>
<dt>translate_av</dt>
<dd><p>if <code>type = "drug"</code>: a column name of the <a href="antibiotics.html">antivirals</a> data set to translate the antibiotic abbreviations to, using <code><a href="av_property.html">av_property()</a></code>. Defaults to <code>FALSE</code>. Using <code>TRUE</code> is equal to using "name".</p></dd>
<dt>thorough_search</dt>
<dd><p>a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> to indicate whether the input must be extensively searched for misspelling and other faulty input values. Setting this to <code>TRUE</code> will take considerably more time than when using <code>FALSE</code>. At default, it will turn <code>TRUE</code> when all input elements contain a maximum of three words.</p></dd>
<dt>info</dt>
<dd><p>a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> to indicate whether a progress bar should be printed, defaults to <code>TRUE</code> only in interactive mode</p></dd>
<dt>...</dt>
<dd><p>arguments passed on to <code><a href="as.av.html">as.av()</a></code></p></dd>
</dl></div>
<div class="section level2">
<h2 id="value">Value<a class="anchor" aria-label="anchor" href="#value"></a></h2>
<p>A <a href="https://rdrr.io/r/base/list.html" class="external-link">list</a>, or a <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a> if <code>collapse</code> is not <code>NULL</code></p>
</div>
<div class="section level2">
<h2 id="details">Details<a class="anchor" aria-label="anchor" href="#details"></a></h2>
<p>This function is also internally used by <code><a href="as.av.html">as.av()</a></code>, although it then only searches for the first drug name and will throw a note if more drug names could have been returned. Note: the <code><a href="as.av.html">as.av()</a></code> function may use very long regular expression to match brand names of antiviral agents. This may fail on some systems.</p><div class="section">
<h3 id="argument-type">Argument <code>type</code><a class="anchor" aria-label="anchor" href="#argument-type"></a></h3>
<p>At default, the function will search for antiviral drug names. All text elements will be searched for official names, ATC codes and brand names. As it uses <code><a href="as.av.html">as.av()</a></code> internally, it will correct for misspelling.</p>
<p>With <code>type = "dose"</code> (or similar, like "dosing", "doses"), all text elements will be searched for <a href="https://rdrr.io/r/base/numeric.html" class="external-link">numeric</a> values that are higher than 100 and do not resemble years. The output will be <a href="https://rdrr.io/r/base/numeric.html" class="external-link">numeric</a>. It supports any unit (g, mg, IE, etc.) and multiple values in one clinical text, see <em>Examples</em>.</p>
<p>With <code>type = "administration"</code> (or abbreviations, like "admin", "adm"), all text elements will be searched for a form of drug administration. It supports the following forms (including common abbreviations): buccal, implant, inhalation, instillation, intravenous, nasal, oral, parenteral, rectal, sublingual, transdermal and vaginal. Abbreviations for oral (such as 'po', 'per os') will become "oral", all values for intravenous (such as 'iv', 'intraven') will become "iv". It supports multiple values in one clinical text, see <em>Examples</em>.</p>
</div>
<div class="section">
<h3 id="argument-collapse">Argument <code>collapse</code><a class="anchor" aria-label="anchor" href="#argument-collapse"></a></h3>
<p>Without using <code>collapse</code>, this function will return a <a href="https://rdrr.io/r/base/list.html" class="external-link">list</a>. This can be convenient to use e.g. inside a <code><a href="https://dplyr.tidyverse.org/reference/mutate.html" class="external-link">mutate()</a></code>):<br><code>df %&gt;% mutate(avx = av_from_text(clinical_text))</code></p>
<p>The returned AV codes can be transformed to official names, groups, etc. with all <code><a href="av_property.html">av_*</a></code> functions such as <code><a href="av_property.html">av_name()</a></code> and <code><a href="av_property.html">av_group()</a></code>, or by using the <code>translate_av</code> argument.</p>
<p>With using <code>collapse</code>, this function will return a <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a>:<br><code>df %&gt;% mutate(avx = av_from_text(clinical_text, collapse = "|"))</code></p>
</div>
</div>
<div class="section level2">
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="fu">av_from_text</span><span class="op">(</span><span class="st">"28/03/2020 valaciclovir po tid"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [[1]]</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'av'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] VALA</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-in"><span><span class="fu">av_from_text</span><span class="op">(</span><span class="st">"28/03/2020 valaciclovir po tid"</span>, type <span class="op">=</span> <span class="st">"admin"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [[1]]</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "oral"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
</code></pre></div>
</div>
</main><aside class="col-md-3"><nav id="toc"><h2>On this page</h2>
</nav></aside></div>
<footer><div class="pkgdown-footer-left">
<p></p><p><code>AMR</code> (for R). Developed at the <a target="_blank" href="https://www.rug.nl" class="external-link">University of Groningen</a> in collaboration with non-profit organisations<br><a target="_blank" href="https://www.certe.nl" class="external-link">Certe Medical Diagnostics and Advice Foundation</a> and <a target="_blank" href="https://www.umcg.nl" class="external-link">University Medical Center Groningen</a>.</p>
</div>
<div class="pkgdown-footer-right">
<p></p><p><a target="_blank" href="https://www.rug.nl" class="external-link"><img src="https://github.com/msberends/AMR/raw/main/pkgdown/logos/logo_rug.svg" style="max-width: 150px;"></a></p>
</div>
</footer></div>
</body></html>

359
reference/av_property.html Normal file
View File

@ -0,0 +1,359 @@
<!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="Use these functions to return a specific property of an antiviral agent from the antivirals data set. All input values will be evaluated internally with as.av()."><title>Get Properties of an Antiviral Agent — av_property • 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.1.3/bootstrap.min.css" rel="stylesheet"><script src="../deps/bootstrap-5.1.3/bootstrap.bundle.min.js"></script><link href="../deps/Fira_Code-0.4.2/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.rawgit.com/afeld/bootstrap-toc/v1.0.1/dist/bootstrap-toc.min.js"></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.6/clipboard.min.js" integrity="sha256-inc5kl9MA1hkeYUt+EC3BhlIgyp/2jDIyBLS6k3UxPI=" crossorigin="anonymous"></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="Get Properties of an Antiviral Agent — av_property"><meta property="og:description" content="Use these functions to return a specific property of an antiviral agent from the antivirals data set. All input values will be evaluated internally with as.av()."><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>
<a href="#main" class="visually-hidden-focusable">Skip to contents</a>
<nav class="navbar fixed-top navbar-dark navbar-expand-lg bg-primary"><div class="container">
<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="">1.8.2.9049</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">
<span class="navbar-toggler-icon"></span>
</button>
<div id="navbar" class="collapse navbar-collapse ms-3">
<ul class="navbar-nav me-auto"><li class="nav-item">
<a class="nav-link" href="../index.html">
<span class="fa fa-home"></span>
Home
</a>
</li>
<li class="active nav-item dropdown">
<a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown" role="button" aria-expanded="false" aria-haspopup="true" id="dropdown--how-to">
<span class="fa fa-question-circle"></span>
How to
</a>
<div class="dropdown-menu" aria-labelledby="dropdown--how-to">
<a class="dropdown-item" href="../articles/AMR.html">
<span class="fa fa-directions"></span>
Conduct AMR analysis
</a>
<a class="dropdown-item" href="../articles/resistance_predict.html">
<span class="fa fa-dice"></span>
Predict antimicrobial resistance
</a>
<a class="dropdown-item" href="../articles/datasets.html">
<span class="fa fa-database"></span>
Data sets for download / own use
</a>
<a class="dropdown-item" href="../articles/PCA.html">
<span class="fa fa-compress"></span>
Conduct principal component analysis for AMR
</a>
<a class="dropdown-item" href="../articles/MDR.html">
<span class="fa fa-skull-crossbones"></span>
Determine multi-drug resistance (MDR)
</a>
<a class="dropdown-item" href="../articles/WHONET.html">
<span class="fa fa-globe-americas"></span>
Work with WHONET data
</a>
<a class="dropdown-item" href="../articles/SPSS.html">
<span class="fa fa-file-upload"></span>
Import data from SPSS/SAS/Stata
</a>
<a class="dropdown-item" href="../articles/EUCAST.html">
<span class="fa fa-exchange-alt"></span>
Apply EUCAST rules
</a>
<a class="dropdown-item" href="../reference/mo_property.html">
<span class="fa fa-bug"></span>
Get properties of a microorganism
</a>
<a class="dropdown-item" href="../reference/ab_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="nav-item">
<a class="nav-link" href="../reference/index.html">
<span class="fa fa-book-open"></span>
Manual
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="../authors.html">
<span class="fa fa-users"></span>
Authors
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="../news/index.html">
<span class="far fa far fa-newspaper"></span>
Changelog
</a>
</li>
</ul><form class="form-inline my-2 my-lg-0" role="search">
<input type="search" class="form-control me-sm-2" aria-label="Toggle navigation" name="search-input" data-search-index="../search.json" id="search-input" placeholder="Search for" autocomplete="off"></form>
<ul class="navbar-nav"><li class="nav-item">
<a class="external-link nav-link" href="https://github.com/msberends/AMR">
<span class="fab fa fab fa-github"></span>
Source Code
</a>
</li>
</ul></div>
</div>
</nav><div class="container template-reference-topic">
<div class="row">
<main id="main" class="col-md-9"><div class="page-header">
<img src="../logo.svg" class="logo" alt=""><h1>Get Properties of an Antiviral Agent</h1>
<small class="dont-index">Source: <a href="https://github.com/msberends/AMR/blob/HEAD/R/av_property.R" class="external-link"><code>R/av_property.R</code></a></small>
<div class="d-none name"><code>av_property.Rd</code></div>
</div>
<div class="ref-description section level2">
<p>Use these functions to return a specific property of an antiviral agent from the <a href="antibiotics.html">antivirals</a> data set. All input values will be evaluated internally with <code><a href="as.av.html">as.av()</a></code>.</p>
</div>
<div class="section level2">
<h2 id="ref-usage">Usage<a class="anchor" aria-label="anchor" href="#ref-usage"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span><span class="fu">av_name</span><span class="op">(</span><span class="va">x</span>, language <span class="op">=</span> <span class="fu"><a href="translate.html">get_AMR_locale</a></span><span class="op">(</span><span class="op">)</span>, tolower <span class="op">=</span> <span class="cn">FALSE</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_cid</span><span class="op">(</span><span class="va">x</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_synonyms</span><span class="op">(</span><span class="va">x</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_tradenames</span><span class="op">(</span><span class="va">x</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_group</span><span class="op">(</span><span class="va">x</span>, language <span class="op">=</span> <span class="fu"><a href="translate.html">get_AMR_locale</a></span><span class="op">(</span><span class="op">)</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_atc</span><span class="op">(</span><span class="va">x</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_loinc</span><span class="op">(</span><span class="va">x</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_ddd</span><span class="op">(</span><span class="va">x</span>, administration <span class="op">=</span> <span class="st">"oral"</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_ddd_units</span><span class="op">(</span><span class="va">x</span>, administration <span class="op">=</span> <span class="st">"oral"</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_info</span><span class="op">(</span><span class="va">x</span>, language <span class="op">=</span> <span class="fu"><a href="translate.html">get_AMR_locale</a></span><span class="op">(</span><span class="op">)</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_url</span><span class="op">(</span><span class="va">x</span>, open <span class="op">=</span> <span class="cn">FALSE</span>, <span class="va">...</span><span class="op">)</span></span>
<span></span>
<span><span class="fu">av_property</span><span class="op">(</span><span class="va">x</span>, property <span class="op">=</span> <span class="st">"name"</span>, language <span class="op">=</span> <span class="fu"><a href="translate.html">get_AMR_locale</a></span><span class="op">(</span><span class="op">)</span>, <span class="va">...</span><span class="op">)</span></span></code></pre></div>
</div>
<div class="section level2">
<h2 id="arguments">Arguments<a class="anchor" aria-label="anchor" href="#arguments"></a></h2>
<dl><dt>x</dt>
<dd><p>any (vector of) text that can be coerced to a valid antiviral agent code with <code><a href="as.av.html">as.av()</a></code></p></dd>
<dt>language</dt>
<dd><p>language of the returned text, defaults to system language (see <code><a href="translate.html">get_AMR_locale()</a></code>) and can also be set with <code>getOption("AMR_locale")</code>. Use <code>language = NULL</code> or <code>language = ""</code> to prevent translation.</p></dd>
<dt>tolower</dt>
<dd><p>a <a href="https://rdrr.io/r/base/logical.html" class="external-link">logical</a> to indicate whether the first <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a> of every output should be transformed to a lower case <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a>.</p></dd>
<dt>...</dt>
<dd><p>other arguments passed on to <code><a href="as.av.html">as.av()</a></code></p></dd>
<dt>administration</dt>
<dd><p>way of administration, either <code>"oral"</code> or <code>"iv"</code></p></dd>
<dt>open</dt>
<dd><p>browse the URL using <code><a href="https://rdrr.io/r/utils/browseURL.html" class="external-link">utils::browseURL()</a></code></p></dd>
<dt>property</dt>
<dd><p>one of the column names of one of the <a href="antibiotics.html">antivirals</a> data set: <code>vector_or(colnames(antivirals), sort = FALSE)</code>.</p></dd>
</dl></div>
<div class="section level2">
<h2 id="value">Value<a class="anchor" aria-label="anchor" href="#value"></a></h2>
<ul><li><p>An <a href="https://rdrr.io/r/base/integer.html" class="external-link">integer</a> in case of <code>av_cid()</code></p></li>
<li><p>A named <a href="https://rdrr.io/r/base/list.html" class="external-link">list</a> in case of <code>av_info()</code> and multiple <code>av_atc()</code>/<code>av_synonyms()</code>/<code>av_tradenames()</code></p></li>
<li><p>A <a href="https://rdrr.io/r/base/double.html" class="external-link">double</a> in case of <code>av_ddd()</code></p></li>
<li><p>A <a href="https://rdrr.io/r/base/character.html" class="external-link">character</a> in all other cases</p></li>
</ul></div>
<div class="section level2">
<h2 id="details">Details<a class="anchor" aria-label="anchor" href="#details"></a></h2>
<p>All output <a href="translate.html">will be translated</a> where possible.</p>
<p>The function <code>av_url()</code> will return the direct URL to the official WHO website. A warning will be returned if the required ATC code is not available.</p>
</div>
<div class="section level2">
<h2 id="source">Source<a class="anchor" aria-label="anchor" href="#source"></a></h2>
<p>World Health Organization (WHO) Collaborating Centre for Drug Statistics Methodology: <a href="https://www.whocc.no/atc_ddd_index/" class="external-link">https://www.whocc.no/atc_ddd_index/</a></p>
<p>European Commission Public Health PHARMACEUTICALS - COMMUNITY REGISTER: <a href="https://ec.europa.eu/health/documents/community-register/html/reg_hum_atc.htm" class="external-link">https://ec.europa.eu/health/documents/community-register/html/reg_hum_atc.htm</a></p>
</div>
<div class="section level2">
<h2 id="reference-data-publicly-available">Reference Data Publicly Available<a class="anchor" aria-label="anchor" href="#reference-data-publicly-available"></a></h2>
<p>All data sets in this <code>AMR</code> package (about microorganisms, antibiotics, R/SI interpretation, EUCAST rules, etc.) are publicly and freely available for download in the following formats: R, MS Excel, Apache Feather, Apache Parquet, SPSS, SAS, and Stata. We also provide tab-separated plain text files that are machine-readable and suitable for input in any software program, such as laboratory information systems. 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>.</p>
</div>
<div class="section level2">
<h2 id="see-also">See also<a class="anchor" aria-label="anchor" href="#see-also"></a></h2>
<div class="dont-index"><p><a href="antibiotics.html">antivirals</a></p></div>
</div>
<div class="section level2">
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="co"># all properties:</span></span></span>
<span class="r-in"><span><span class="fu">av_name</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Aciclovir"</span>
<span class="r-in"><span><span class="fu">av_atc</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "J05AB01"</span>
<span class="r-in"><span><span class="fu">av_cid</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 135398513</span>
<span class="r-in"><span><span class="fu">av_synonyms</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "acicloftal" "aciclovier" "aciclovirum" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [4] "activir" "acyclofoam" "acycloguanosine" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] "acyclovir" "acyclovir lauriad" "avaclyr" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] "cargosil" "cyclovir" "genvir" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [13] "gerpevir" "hascovir" "maynar" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [16] "novirus" "poviral" "sitavig" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [19] "sitavir" "vipral" "viropump" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [22] "virorax" "zovirax" "zyclir" </span>
<span class="r-in"><span><span class="fu">av_tradenames</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "acicloftal" "aciclovier" "aciclovirum" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [4] "activir" "acyclofoam" "acycloguanosine" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] "acyclovir" "acyclovir lauriad" "avaclyr" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] "cargosil" "cyclovir" "genvir" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [13] "gerpevir" "hascovir" "maynar" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [16] "novirus" "poviral" "sitavig" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [19] "sitavir" "vipral" "viropump" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [22] "virorax" "zovirax" "zyclir" </span>
<span class="r-in"><span><span class="fu">av_group</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Nucleosides and nucleotides excl. reverse transcriptase inhibitors"</span>
<span class="r-in"><span><span class="fu">av_url</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Aciclovir </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> "https://www.whocc.no/atc_ddd_index/?code=J05AB01&amp;showdescription=no" </span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># smart lowercase tranformation</span></span></span>
<span class="r-in"><span><span class="fu">av_name</span><span class="op">(</span>x <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">"ACI"</span>, <span class="st">"VALA"</span><span class="op">)</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Aciclovir" "Valaciclovir"</span>
<span class="r-in"><span><span class="fu">av_name</span><span class="op">(</span>x <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">"ACI"</span>, <span class="st">"VALA"</span><span class="op">)</span>, tolower <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "aciclovir" "valaciclovir"</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># defined daily doses (DDD)</span></span></span>
<span class="r-in"><span><span class="fu">av_ddd</span><span class="op">(</span><span class="st">"ACI"</span>, <span class="st">"oral"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 4</span>
<span class="r-in"><span><span class="fu">av_ddd_units</span><span class="op">(</span><span class="st">"ACI"</span>, <span class="st">"oral"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "g"</span>
<span class="r-in"><span><span class="fu">av_ddd</span><span class="op">(</span><span class="st">"ACI"</span>, <span class="st">"iv"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 4</span>
<span class="r-in"><span><span class="fu">av_ddd_units</span><span class="op">(</span><span class="st">"ACI"</span>, <span class="st">"iv"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "g"</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu">av_info</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span> <span class="co"># all properties as a list</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $av</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "ACI"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $cid</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 135398513</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $name</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Aciclovir"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $group</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Nucleosides and nucleotides excl. reverse transcriptase inhibitors"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $atc</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "J05AB01"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $tradenames</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "acicloftal" "aciclovier" "aciclovirum" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [4] "activir" "acyclofoam" "acycloguanosine" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] "acyclovir" "acyclovir lauriad" "avaclyr" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] "cargosil" "cyclovir" "genvir" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [13] "gerpevir" "hascovir" "maynar" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [16] "novirus" "poviral" "sitavig" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [19] "sitavir" "vipral" "viropump" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [22] "virorax" "zovirax" "zyclir" </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $loinc</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] ""</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $ddd</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $ddd$oral</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $ddd$oral$amount</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 4</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $ddd$oral$units</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "g"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $ddd$iv</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $ddd$iv$amount</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 4</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> $ddd$iv$units</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "g"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> </span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># all av_* functions use as.av() internally, so you can go from 'any' to 'any':</span></span></span>
<span class="r-in"><span><span class="fu">av_atc</span><span class="op">(</span><span class="st">"ACI"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "J05AB01"</span>
<span class="r-in"><span><span class="fu">av_group</span><span class="op">(</span><span class="st">"J05AB01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Nucleosides and nucleotides excl. reverse transcriptase inhibitors"</span>
<span class="r-in"><span><span class="fu">av_loinc</span><span class="op">(</span><span class="st">"abacavir"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "29113-8" "78772-1" "78773-9" "79134-3" "80118-3"</span>
<span class="r-in"><span><span class="fu">av_name</span><span class="op">(</span><span class="st">"29113-8"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Abacavir"</span>
<span class="r-in"><span><span class="fu">av_name</span><span class="op">(</span><span class="fl">135398513</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Aciclovir"</span>
<span class="r-in"><span><span class="fu">av_name</span><span class="op">(</span><span class="st">"J05AB01"</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] "Aciclovir"</span>
</code></pre></div>
</div>
</main><aside class="col-md-3"><nav id="toc"><h2>On this page</h2>
</nav></aside></div>
<footer><div class="pkgdown-footer-left">
<p></p><p><code>AMR</code> (for R). Developed at the <a target="_blank" href="https://www.rug.nl" class="external-link">University of Groningen</a> in collaboration with non-profit organisations<br><a target="_blank" href="https://www.certe.nl" class="external-link">Certe Medical Diagnostics and Advice Foundation</a> and <a target="_blank" href="https://www.umcg.nl" class="external-link">University Medical Center Groningen</a>.</p>
</div>
<div class="pkgdown-footer-right">
<p></p><p><a target="_blank" href="https://www.rug.nl" class="external-link"><img src="https://github.com/msberends/AMR/raw/main/pkgdown/logos/logo_rug.svg" style="max-width: 150px;"></a></p>
</div>
</footer></div>
</body></html>

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -84,6 +84,11 @@ count_resistant() should be used to count resistant isolates, count_susceptible(
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -84,6 +84,11 @@ To improve the interpretation of the antibiogram before EUCAST rules are applied
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -84,6 +84,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -177,39 +182,40 @@
<span class="r-in"><span><span class="va">df</span> <span class="op">&lt;-</span> <span class="va">example_isolates</span><span class="op">[</span><span class="fu"><a href="https://rdrr.io/r/base/sample.html" class="external-link">sample</a></span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/base/seq.html" class="external-link">seq_len</a></span><span class="op">(</span><span class="fl">2000</span><span class="op">)</span>, size <span class="op">=</span> <span class="fl">200</span><span class="op">)</span>, <span class="op">]</span></span></span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu">get_episode</span><span class="op">(</span><span class="va">df</span><span class="op">$</span><span class="va">date</span>, episode_days <span class="op">=</span> <span class="fl">60</span><span class="op">)</span> <span class="co"># indices</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 47 62 48 9 37 56 39 32 57 43 62 17 55 10 54 45 14 28 42 56 60 34 7 29 2</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [26] 44 55 6 55 36 5 43 8 32 42 31 58 8 33 1 50 27 20 13 2 60 15 59 11 59</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [51] 56 58 6 41 56 47 21 11 42 59 1 24 46 38 30 4 41 11 24 31 53 36 11 9 13</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [76] 51 20 13 40 21 44 22 36 50 23 2 52 18 54 59 25 62 52 59 35 49 41 24 17 62</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [101] 45 3 19 56 16 44 6 53 16 46 47 60 28 1 54 17 27 58 10 29 27 54 43 27 54</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [126] 51 9 55 8 33 22 19 61 47 37 60 62 25 32 49 13 8 46 1 31 8 2 13 5 37</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [151] 12 55 32 25 13 46 19 48 47 61 21 1 1 59 4 8 19 49 40 32 8 60 13 10 27</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [176] 40 38 26 20 4 8 15 22 56 58 16 8 55 14 10 29 12 61 11 48 42 18 46 60 20</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 1 28 42 53 40 26 58 46 6 36 25 27 6 33 51 28 53 40 17 63 14 14 52 12 39</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [26] 45 31 5 43 44 51 42 1 46 53 41 47 55 54 14 7 25 13 5 55 61 60 58 62 11</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [51] 23 38 14 62 1 63 1 36 45 63 8 3 56 13 37 17 32 34 23 28 57 7 60 30 3</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [76] 63 10 59 61 59 9 59 58 38 5 20 48 51 11 4 7 11 37 60 34 33 17 53 59 36</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [101] 33 24 25 43 49 39 61 14 13 55 36 9 9 7 11 12 52 62 62 2 54 22 47 13 49</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [126] 31 17 5 8 4 62 48 60 2 58 37 54 61 39 21 10 44 27 2 17 26 15 62 25 62</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [151] 29 9 20 59 18 46 8 14 27 32 5 50 55 16 11 32 58 57 39 39 33 49 58 50 45</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [176] 43 35 61 38 50 1 55 22 55 2 63 59 41 55 31 22 18 19 30 14 52 55 57 57 52</span>
<span class="r-in"><span><span class="fu">is_new_episode</span><span class="op">(</span><span class="va">df</span><span class="op">$</span><span class="va">date</span>, episode_days <span class="op">=</span> <span class="fl">60</span><span class="op">)</span> <span class="co"># TRUE/FALSE</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] FALSE FALSE TRUE FALSE TRUE FALSE TRUE FALSE TRUE TRUE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [13] FALSE FALSE FALSE FALSE TRUE FALSE FALSE FALSE FALSE TRUE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [25] FALSE TRUE FALSE TRUE TRUE FALSE FALSE FALSE FALSE FALSE TRUE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [37] FALSE FALSE TRUE FALSE TRUE FALSE FALSE FALSE FALSE FALSE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [49] FALSE TRUE FALSE FALSE FALSE FALSE FALSE TRUE TRUE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [61] FALSE FALSE FALSE FALSE TRUE FALSE TRUE FALSE TRUE FALSE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [73] FALSE TRUE FALSE TRUE FALSE FALSE FALSE FALSE FALSE TRUE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [85] TRUE FALSE TRUE TRUE FALSE FALSE FALSE FALSE FALSE FALSE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [97] FALSE FALSE FALSE FALSE TRUE TRUE FALSE FALSE FALSE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [109] TRUE TRUE FALSE FALSE TRUE FALSE TRUE TRUE TRUE TRUE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [121] FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [133] FALSE FALSE FALSE FALSE TRUE FALSE TRUE FALSE FALSE FALSE FALSE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [145] FALSE FALSE TRUE FALSE TRUE FALSE TRUE FALSE FALSE TRUE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [157] FALSE FALSE FALSE TRUE FALSE FALSE FALSE FALSE TRUE TRUE FALSE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [169] FALSE FALSE FALSE FALSE FALSE TRUE FALSE TRUE TRUE TRUE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [181] FALSE FALSE FALSE TRUE FALSE FALSE FALSE FALSE FALSE FALSE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [193] FALSE TRUE FALSE FALSE FALSE FALSE TRUE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] FALSE FALSE FALSE TRUE FALSE TRUE FALSE TRUE FALSE TRUE FALSE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [13] TRUE TRUE FALSE FALSE FALSE TRUE FALSE FALSE TRUE FALSE FALSE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [25] FALSE FALSE FALSE FALSE TRUE TRUE FALSE TRUE TRUE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [37] TRUE FALSE TRUE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [49] FALSE FALSE FALSE FALSE FALSE FALSE FALSE TRUE FALSE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [61] FALSE FALSE TRUE FALSE TRUE FALSE FALSE FALSE TRUE TRUE FALSE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [73] TRUE TRUE TRUE FALSE TRUE TRUE FALSE FALSE FALSE FALSE TRUE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [85] FALSE TRUE FALSE TRUE FALSE TRUE FALSE FALSE FALSE FALSE TRUE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [97] FALSE FALSE FALSE FALSE FALSE TRUE FALSE FALSE TRUE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [109] FALSE FALSE FALSE FALSE FALSE FALSE TRUE FALSE FALSE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [121] FALSE FALSE FALSE TRUE FALSE TRUE TRUE FALSE TRUE FALSE TRUE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [133] FALSE FALSE FALSE FALSE FALSE FALSE TRUE TRUE FALSE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [145] FALSE FALSE TRUE FALSE TRUE FALSE TRUE TRUE FALSE FALSE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [157] FALSE FALSE FALSE FALSE TRUE TRUE FALSE TRUE FALSE TRUE FALSE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [169] FALSE FALSE FALSE FALSE FALSE FALSE TRUE FALSE TRUE TRUE FALSE FALSE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [181] FALSE TRUE FALSE FALSE TRUE FALSE FALSE TRUE FALSE FALSE TRUE TRUE</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [193] TRUE FALSE FALSE TRUE FALSE FALSE FALSE FALSE</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># filter on results from the third 60-day episode only, using base R</span></span></span>
<span class="r-in"><span><span class="va">df</span><span class="op">[</span><span class="fu"><a href="https://rdrr.io/r/base/which.html" class="external-link">which</a></span><span class="op">(</span><span class="fu">get_episode</span><span class="op">(</span><span class="va">df</span><span class="op">$</span><span class="va">date</span>, <span class="fl">60</span><span class="op">)</span> <span class="op">==</span> <span class="fl">3</span><span class="op">)</span>, <span class="op">]</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 1 × 46</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> date patient age gender ward mo PEN OXA FLC AMX </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494; font-style: italic;">&lt;date&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&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;mo&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">1</span> 2002-07-23 F35553 51 M ICU B_STPHY_AURS R NA S R </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 2 × 46</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> date patient age gender ward mo PEN OXA FLC AMX </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494; font-style: italic;">&lt;date&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&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;mo&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span> <span style="color: #949494; font-style: italic;">&lt;rsi&gt;</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">1</span> 2002-06-23 798871 82 M Clinical B_ENTRC_FCLS NA NA NA NA </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">2</span> 2002-06-05 24D393 20 F Clinical B_ESCHR_COLI R NA NA NA </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># … with 36 more variables: AMC &lt;rsi&gt;, AMP &lt;rsi&gt;, TZP &lt;rsi&gt;, CZO &lt;rsi&gt;,</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># FEP &lt;rsi&gt;, CXM &lt;rsi&gt;, FOX &lt;rsi&gt;, CTX &lt;rsi&gt;, CAZ &lt;rsi&gt;, CRO &lt;rsi&gt;,</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># GEN &lt;rsi&gt;, TOB &lt;rsi&gt;, AMK &lt;rsi&gt;, KAN &lt;rsi&gt;, TMP &lt;rsi&gt;, SXT &lt;rsi&gt;,</span></span>
@ -245,16 +251,16 @@
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># Groups: condition [3]</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> patient date condition new_episode</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;date&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;lgl&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> A97263 2013-11-23 B FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 3D2C93 2017-12-13 A FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 919B60 2013-12-31 B FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> EB1709 2003-12-27 A FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 394307 2011-02-24 A FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 964129 2016-06-17 C FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 13DF24 2011-08-14 C FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 451000 2009-08-29 B FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> C34980 2016-06-28 A TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 4C9760 2012-09-06 A FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> 067927 2002-02-05 A FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 733957 2008-10-10 B FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 686445 2012-05-24 B TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> 900485 2015-05-27 A FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 50C8DB 2011-09-01 A FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 181687 2008-05-04 B TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 675894 2016-06-03 B FALSE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 835073 2013-09-27 B TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> 000090 2003-10-08 A TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 874171 2010-10-26 C TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># … with 190 more rows</span></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://dplyr.tidyverse.org" class="external-link">"dplyr"</a></span><span class="op">)</span><span class="op">)</span> <span class="op">{</span></span></span>
<span class="r-in"><span> <span class="va">df</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span></span>
@ -266,19 +272,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-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 200 × 5</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># Groups: ward, patient [177]</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> ward date patient new_index new_logical</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;date&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&gt;</span> <span style="color: #949494; font-style: italic;">&lt;lgl&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> Clinical 2013-11-23 A97263 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> ICU 2017-12-13 3D2C93 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Clinical 2013-12-31 919B60 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> ICU 2003-12-27 EB1709 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> Clinical 2011-02-24 394307 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> Clinical 2016-06-17 964129 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> Clinical 2011-08-14 13DF24 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> Clinical 2009-08-29 451000 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> Clinical 2016-06-28 C34980 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> Clinical 2012-09-06 4C9760 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># Groups: ward, patient [175]</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> ward date patient new_index new_logical</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;date&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;dbl&gt;</span> <span style="color: #949494; font-style: italic;">&lt;lgl&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> ICU 2002-02-05 067927 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> ICU 2008-10-10 733957 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> Clinical 2012-05-24 686445 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> ICU 2015-05-27 900485 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> Clinical 2011-09-01 50C8DB 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> Outpatient 2008-05-04 181687 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> ICU 2016-06-03 675894 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> Clinical 2013-09-27 835073 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> ICU 2003-10-08 000090 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> Clinical 2010-10-26 874171 1 TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># … with 190 more rows</span></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://dplyr.tidyverse.org" class="external-link">"dplyr"</a></span><span class="op">)</span><span class="op">)</span> <span class="op">{</span></span></span>
<span class="r-in"><span> <span class="va">df</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span></span>
@ -293,9 +299,9 @@
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># A tibble: 3 × 5</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> ward n_patients n_episodes_365 n_episodes_60 n_episodes_30</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;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> Clinical 105 15 51 69</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">2</span> ICU 60 12 36 45</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">3</span> Outpatient 12 6 11 12</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">1</span> Clinical 105 14 55 71</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">2</span> ICU 55 12 31 40</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">3</span> Outpatient 15 6 12 14</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://dplyr.tidyverse.org" class="external-link">"dplyr"</a></span><span class="op">)</span><span class="op">)</span> <span class="op">{</span></span></span>
<span class="r-in"><span></span></span>
<span class="r-in"><span> <span class="co"># grouping on patients and microorganisms leads to the same</span></span></span>
@ -325,19 +331,19 @@
<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="fu"><a href="https://dplyr.tidyverse.org/reference/group_data.html" class="external-link">group_vars</a></span><span class="op">(</span><span class="va">.</span><span class="op">)</span>, <span class="va">flag_episode</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: 200 × 4</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># Groups: patient, mo, ward [188]</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> patient mo ward flag_episode</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;mo&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;lgl&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> A97263 B_KLBSL_PNMN Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 3D2C93 B_STPHY_EPDR ICU TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 919B60 B_STPHY_AURS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> EB1709 B_STRPT_PNMN ICU TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 394307 B_STPHY_AURS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 964129 B_SERRT_MRCS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 13DF24 B_STPHY_CONS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 451000 B_STPHY_CONS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> C34980 B_STRPT_PYGN Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 4C9760 B_ESCHR_COLI Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># Groups: patient, mo, ward [186]</span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> patient mo ward flag_episode</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;mo&gt;</span> <span style="color: #949494; font-style: italic;">&lt;chr&gt;</span> <span style="color: #949494; font-style: italic;">&lt;lgl&gt;</span> </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 1</span> 067927 B_SERRT_MRCS ICU TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 2</span> 733957 B_ESCHR_COLI ICU TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 3</span> 686445 B_STPHY_CONS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 4</span> 900485 B_STRPT_MITS ICU TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 5</span> 50C8DB B_STPHY_EPDR Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 6</span> 181687 B_STRPT_ANGN Outpatient TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 7</span> 675894 B_ESCHR_COLI ICU TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 8</span> 835073 B_STPHY_HMNS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;"> 9</span> 000090 B_STPHY_EPDR ICU TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #BCBCBC;">10</span> 874171 B_STPHY_CONS Clinical TRUE </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> <span style="color: #949494;"># … with 190 more rows</span></span>
<span class="r-in"><span><span class="co"># }</span></span></span>
</code></pre></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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -300,7 +305,33 @@
</dt>
<dd>Guess Antibiotic Column</dd>
</dl></div><div class="section level2">
<h2 id="background-information-on-included-data">Background information on included data<a class="anchor" aria-label="anchor" href="#background-information-on-included-data"></a></h2>
<h2 id="other-antiviral-drugs">Other: antiviral drugs<a class="anchor" aria-label="anchor" href="#other-antiviral-drugs"></a></h2>
<p class="section-desc"></p><p>This package also provides extensive support for antiviral agents, even though it is not the primary scope of this package. Working with data containing information about antiviral drugs was never easier. Use these functions to get valid properties of antiviral drugs from any input or to clean your input. You can even retrieve drug names and doses from clinical text records, using <code><a href="../reference/av_from_text.html">av_from_text()</a></code>.</p>
</div><div id="" class="section level2">
<dl><dt>
<code><a href="as.av.html">as.av()</a></code> <code><a href="as.av.html">is.av()</a></code>
</dt>
<dd>Transform Input to an Antiviral Agent ID</dd>
</dl><dl><dt>
<code><a href="av_property.html">av_name()</a></code> <code><a href="av_property.html">av_cid()</a></code> <code><a href="av_property.html">av_synonyms()</a></code> <code><a href="av_property.html">av_tradenames()</a></code> <code><a href="av_property.html">av_group()</a></code> <code><a href="av_property.html">av_atc()</a></code> <code><a href="av_property.html">av_loinc()</a></code> <code><a href="av_property.html">av_ddd()</a></code> <code><a href="av_property.html">av_ddd_units()</a></code> <code><a href="av_property.html">av_info()</a></code> <code><a href="av_property.html">av_url()</a></code> <code><a href="av_property.html">av_property()</a></code>
</dt>
<dd>Get Properties of an Antiviral Agent</dd>
</dl><dl><dt>
<code><a href="av_from_text.html">av_from_text()</a></code>
</dt>
<dd>Retrieve Antiviral Drug Names and Doses from Clinical Text</dd>
</dl></div><div class="section level2">
<h2 id="other-background-information-on-included-data">Other: background information on included data<a class="anchor" aria-label="anchor" href="#other-background-information-on-included-data"></a></h2>
<p class="section-desc"></p><p>Some pages about our package and its external sources. Be sure to read our <a href="./../articles/index.html">How Tos</a> for more information about how to work with functions in this package.</p>
@ -334,7 +365,7 @@
<code><a href="antibiotics.html">antibiotics</a></code> <code><a href="antibiotics.html">antivirals</a></code>
</dt>
<dd>Data Sets with 585 Antimicrobial Drugs</dd>
<dd>Data Sets with 603 Antimicrobial Drugs</dd>
</dl><dl><dt>
<code><a href="intrinsic_resistant.html">intrinsic_resistant</a></code>

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -167,9 +172,9 @@
<div class="section level2">
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="fu">kurtosis</span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/stats/Normal.html" class="external-link">rnorm</a></span><span class="op">(</span><span class="fl">10000</span><span class="op">)</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 2.934002</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 2.986231</span>
<span class="r-in"><span><span class="fu">kurtosis</span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/stats/Normal.html" class="external-link">rnorm</a></span><span class="op">(</span><span class="fl">10000</span><span class="op">)</span>, excess <span class="op">=</span> <span class="cn">TRUE</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] -0.03517118</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] -0.002932157</span>
</code></pre></div>
</div>
</main><aside class="col-md-3"><nav id="toc"><h2>On this page</h2>

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -195,11 +200,11 @@
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="va">x</span> <span class="op">&lt;-</span> <span class="fu"><a href="random.html">random_mic</a></span><span class="op">(</span><span class="fl">10</span><span class="op">)</span></span></span>
<span class="r-in"><span><span class="va">x</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'mic'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 1 0.005 2 0.125 0.002 0.5 0.0625 0.5 &lt;=0.001</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] 0.002 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 2 0.01 0.01 2 0.125 &lt;=0.005 0.0625 &lt;=0.005 4 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] &gt;=256 </span>
<span class="r-in"><span><span class="fu">mean_amr_distance</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> [1] 1.04271494 -0.78781830 1.28219266 0.32428178 -1.10439062 0.80323722</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] 0.08480407 0.80323722 -1.34386834 -1.10439062</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.6440970 -0.8222686 -0.8222686 0.6440970 -0.1232464 -1.0141044</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] -0.3150822 -1.0141044 0.8359328 1.9869478</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="va">y</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>
<span class="r-in"><span> id <span class="op">=</span> <span class="va">LETTERS</span><span class="op">[</span><span class="fl">1</span><span class="op">:</span><span class="fl">10</span><span class="op">]</span>,</span></span>
@ -209,38 +214,38 @@
<span class="r-in"><span> tobr <span class="op">=</span> <span class="fu"><a href="random.html">random_mic</a></span><span class="op">(</span><span class="fl">10</span>, ab <span class="op">=</span> <span class="st">"tobr"</span>, mo <span class="op">=</span> <span class="st">"Escherichia coli"</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="va">y</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> id amox cipr gent tobr</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 A 4 0.5 &lt;=1 4</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 B 8 &gt;=1 2 &gt;=16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 C &gt;=16 0.5 2 0.5</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 D &gt;=16 0.25 2 &gt;=16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 E 8 0.25 2 1</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 F 4 0.25 4 1</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 G &gt;=16 0.5 2 1</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 H 4 0.25 2 &gt;=16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 I 4 0.5 4 8</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 J 8 0.025 4 0.5</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> id amox cipr gent tobr</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 A 8 0.25 2 8</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 B &gt;=32 0.125 &lt;=0.5 8</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 C &gt;=32 0.0625 &lt;=0.5 4</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 D 4 0.5 2 8</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 E 8 &lt;=0.025 2 16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 F 16 0.125 &gt;=4 8</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 G 4 2 &lt;=0.5 &lt;=1</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 H 4 0.5 &gt;=4 4</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 I 16 0.0625 &lt;=0.5 8</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 J &gt;=32 0.0625 &lt;=0.5 4</span>
<span class="r-in"><span><span class="fu">mean_amr_distance</span><span class="op">(</span><span class="va">y</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Calculating mean AMR distance based on columns "amox", "cipr", "gent",</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> "id" and "tobr"</span>
<span class="r-wrn co"><span class="r-pr">#&gt;</span> <span class="warning">Warning: </span>NAs introduced by coercion</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] -0.54407797 0.54766468 0.06869358 0.48271367 -0.27421097 -0.16444638</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] 0.18654471 -0.08832657 0.36434257 -0.57889732</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.25292590 0.13456515 -0.22939265 0.18846902 0.04421622 0.50727140</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [7] -0.62066776 0.14690263 -0.19489727 -0.22939265</span>
<span class="r-in"><span><span class="va">y</span><span class="op">$</span><span class="va">amr_distance</span> <span class="op">&lt;-</span> <span class="fu">mean_amr_distance</span><span class="op">(</span><span class="va">y</span>, <span class="fu">where</span><span class="op">(</span><span class="va">is.mic</span><span class="op">)</span><span class="op">)</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Calculating mean AMR distance based on columns "amox", "cipr", "gent" and</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> "tobr"</span>
<span class="r-in"><span><span class="va">y</span><span class="op">[</span><span class="fu"><a href="https://rdrr.io/r/base/order.html" class="external-link">order</a></span><span class="op">(</span><span class="va">y</span><span class="op">$</span><span class="va">amr_distance</span><span class="op">)</span>, <span class="op">]</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> id amox cipr gent tobr amr_distance</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 J 8 0.025 4 0.5 -0.57889732</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 A 4 0.5 &lt;=1 4 -0.54407797</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 E 8 0.25 2 1 -0.27421097</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 F 4 0.25 4 1 -0.16444638</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 H 4 0.25 2 &gt;=16 -0.08832657</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 C &gt;=16 0.5 2 0.5 0.06869358</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 G &gt;=16 0.5 2 1 0.18654471</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 I 4 0.5 4 8 0.36434257</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 D &gt;=16 0.25 2 &gt;=16 0.48271367</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 B 8 &gt;=1 2 &gt;=16 0.54766468</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> id amox cipr gent tobr amr_distance</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 G 4 2 &lt;=0.5 &lt;=1 -0.62066776</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 C &gt;=32 0.0625 &lt;=0.5 4 -0.22939265</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 J &gt;=32 0.0625 &lt;=0.5 4 -0.22939265</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 I 16 0.0625 &lt;=0.5 8 -0.19489727</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 E 8 &lt;=0.025 2 16 0.04421622</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 B &gt;=32 0.125 &lt;=0.5 8 0.13456515</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 H 4 0.5 &gt;=4 4 0.14690263</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 D 4 0.5 2 8 0.18846902</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 A 8 0.25 2 8 0.25292590</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 F 16 0.125 &gt;=4 8 0.50727140</span>
<span class="r-in"><span></span></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://dplyr.tidyverse.org" class="external-link">"dplyr"</a></span><span class="op">)</span><span class="op">)</span> <span class="op">{</span></span></span>
<span class="r-in"><span> <span class="va">y</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span></span>
@ -252,17 +257,17 @@
<span class="r-in"><span><span class="op">}</span></span></span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> Calculating mean AMR distance based on columns "amox", "cipr", "gent" and</span>
<span class="r-msg co"><span class="r-pr">#&gt;</span> "tobr"</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> id amox cipr gent tobr amr_distance check_id_C</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 C &gt;=16 0.5 2 0.5 0.06869358 0.0000000</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 G &gt;=16 0.5 2 1 0.18654471 0.1178511</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 H 4 0.25 2 &gt;=16 -0.08832657 0.1570202</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 F 4 0.25 4 1 -0.16444638 0.2331400</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 I 4 0.5 4 8 0.36434257 0.2956490</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 E 8 0.25 2 1 -0.27421097 0.3429046</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 D &gt;=16 0.25 2 &gt;=16 0.48271367 0.4140201</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 B 8 &gt;=1 2 &gt;=16 0.54766468 0.4789711</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 A 4 0.5 &lt;=1 4 -0.54407797 0.6127716</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 J 8 0.025 4 0.5 -0.57889732 0.6475909</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> id amox cipr gent tobr amr_distance check_id_C</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 1 C &gt;=32 0.0625 &lt;=0.5 4 -0.22939265 0.00000000</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 2 J &gt;=32 0.0625 &lt;=0.5 4 -0.22939265 0.00000000</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 3 I 16 0.0625 &lt;=0.5 8 -0.19489727 0.03449538</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 4 E 8 &lt;=0.025 2 16 0.04421622 0.27360887</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 5 B &gt;=32 0.125 &lt;=0.5 8 0.13456515 0.36395780</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 6 H 4 0.5 &gt;=4 4 0.14690263 0.37629528</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 7 G 4 2 &lt;=0.5 &lt;=1 -0.62066776 0.39127511</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 8 D 4 0.5 2 8 0.18846902 0.41786167</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 9 A 8 0.25 2 8 0.25292590 0.48231854</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> 10 F 16 0.125 &gt;=4 8 0.50727140 0.73666405</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://dplyr.tidyverse.org" class="external-link">"dplyr"</a></span><span class="op">)</span><span class="op">)</span> <span class="op">{</span></span></span>
<span class="r-in"><span> <span class="co"># support for groups</span></span></span>
<span class="r-in"><span> <span class="va">example_isolates</span> <span class="op"><a href="https://magrittr.tidyverse.org/reference/pipe.html" class="external-link">%&gt;%</a></span></span></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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -84,6 +84,11 @@ This is the fastest way to have your organisation (or analysis) specific codes p
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 52 KiB

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 27 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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -84,6 +84,11 @@ resistance() should be used to calculate resistance, susceptibility() should be
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -178,43 +183,42 @@
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="fu">random_mic</span><span class="op">(</span><span class="fl">25</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'mic'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 8 64 1 128 0.25 &lt;=0.001 0.25 0.01 0.025 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] 128 &lt;=0.001 128 &gt;=256 2 0.025 8 &gt;=256 0.002 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [19] 1 0.5 0.25 2 &lt;=0.001 1 2 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.0625 0.01 4 64 0.005 32 2 0.01 &lt;=0.001</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] 8 128 64 2 8 0.002 0.01 0.0625 0.25 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [19] 64 0.01 16 0.25 0.0625 &gt;=256 &lt;=0.001</span>
<span class="r-in"><span><span class="fu">random_disk</span><span class="op">(</span><span class="fl">25</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'disk'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 7 18 38 42 43 47 45 10 45 24 17 15 24 45 26 23 44 50 45 50 19 28 25 47 11</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 29 36 20 49 33 28 28 23 39 22 10 47 23 49 47 42 30 47 22 37 47 9 19 45 37</span>
<span class="r-in"><span><span class="fu">random_rsi</span><span class="op">(</span><span class="fl">25</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'rsi'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] R S R I I R I R R R I R I I S I I S I R I R R I S</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] I S I I I S R R S I R I I R I R S R S R S I R R R</span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="co"># \donttest{</span></span></span>
<span class="r-in"><span><span class="co"># make the random generation more realistic by setting a bug and/or drug:</span></span></span>
<span class="r-in"><span><span class="fu">random_mic</span><span class="op">(</span><span class="fl">25</span>, <span class="st">"Klebsiella pneumoniae"</span><span class="op">)</span> <span class="co"># range 0.0625-64</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'mic'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.025 0.001 2 0.5 8 0.01 0.005 32 256 4 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [11] 0.025 0.025 0.025 0.002 0.25 4 1 0.0625 0.025 0.0625</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [21] 2 8 0.002 0.5 16 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.005 32 0.025 0.005 0.005 4 2 0.005 0.01 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] 0.5 2 0.25 0.025 2 &lt;=0.001 0.5 8 4 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [19] 8 0.025 8 0.025 8 2 0.0625 </span>
<span class="r-in"><span><span class="fu">random_mic</span><span class="op">(</span><span class="fl">25</span>, <span class="st">"Klebsiella pneumoniae"</span>, <span class="st">"meropenem"</span><span class="op">)</span> <span class="co"># range 0.0625-16</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'mic'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] &gt;=64 32 1 &lt;=0.5 16 1 16 2 1 1 32 2 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [13] &lt;=0.5 2 32 2 8 4 16 32 2 1 4 1 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [25] 8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 16 16 4 32 0.5 &gt;=64 8 1 1 &gt;=64 0.5 32 &gt;=64 0.5 &gt;=64</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [16] 0.5 32 16 4 1 32 &gt;=64 0.5 0.5 1 </span>
<span class="r-in"><span><span class="fu">random_mic</span><span class="op">(</span><span class="fl">25</span>, <span class="st">"Streptococcus pneumoniae"</span>, <span class="st">"meropenem"</span><span class="op">)</span> <span class="co"># range 0.0625-4</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'mic'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.125 &gt;=4 0.5 1 1 0.5 1 0.125 0.125 0.25 0.125 1 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [13] 0.25 0.125 0.5 0.5 0.125 &gt;=4 &gt;=4 2 &gt;=4 0.5 2 1 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [25] 2 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] &gt;=8 2 1 &gt;=8 2 2 &gt;=8 1 0.5 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [10] 1 1 2 0.5 2 0.5 0.5 0.5 &gt;=8 </span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [19] 0.25 &lt;=0.125 1 &lt;=0.125 0.25 0.5 2 </span>
<span class="r-in"><span></span></span>
<span class="r-in"><span><span class="fu">random_disk</span><span class="op">(</span><span class="fl">25</span>, <span class="st">"Klebsiella pneumoniae"</span><span class="op">)</span> <span class="co"># range 8-50</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'disk'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 42 28 19 47 45 39 48 47 43 30 43 37 43 34 16 45 36 22 26 25 11 28 17 11 41</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 42 24 15 28 24 44 34 35 49 40 50 26 49 10 50 42 24 43 18 14 47 41 50 33 29</span>
<span class="r-in"><span><span class="fu">random_disk</span><span class="op">(</span><span class="fl">25</span>, <span class="st">"Klebsiella pneumoniae"</span>, <span class="st">"ampicillin"</span><span class="op">)</span> <span class="co"># range 11-17</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'disk'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 13 16 12 16 14 12 15 14 12 11 13 16 12 14 16 12 13 12 17 16 11 14 12 13 15</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 14 15 15 12 17 12 11 16 13 12 14 12 14 16 15 17 11 13 13 13 13 12 15 11 13</span>
<span class="r-in"><span><span class="fu">random_disk</span><span class="op">(</span><span class="fl">25</span>, <span class="st">"Streptococcus pneumoniae"</span>, <span class="st">"ampicillin"</span><span class="op">)</span> <span class="co"># range 12-27</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> Class 'disk'</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 25 18 19 19 27 25 18 24 27 23 18 17 16 27 26 15 25 26 24 26 15 17 26 20 16</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 23 16 24 19 17 23 16 21 15 19 21 22 16 23 26 15 25 22 20 26 26 16 22 26 23</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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -84,6 +84,11 @@ When negative ('left-skewed'): the left tail is longer; the mass of the distribu
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">
@ -166,7 +171,7 @@ When negative ('left-skewed'): the left tail is longer; the mass of the distribu
<div class="section level2">
<h2 id="ref-examples">Examples<a class="anchor" aria-label="anchor" href="#ref-examples"></a></h2>
<div class="sourceCode"><pre class="sourceCode r"><code><span class="r-in"><span><span class="fu">skewness</span><span class="op">(</span><span class="fu"><a href="https://rdrr.io/r/stats/Uniform.html" class="external-link">runif</a></span><span class="op">(</span><span class="fl">1000</span><span class="op">)</span><span class="op">)</span></span></span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.01305892</span>
<span class="r-out co"><span class="r-pr">#&gt;</span> [1] 0.03343928</span>
</code></pre></div>
</div>
</main><aside class="col-md-3"><nav id="toc"><h2>On this page</h2>

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="">1.8.2.9047</small>
<small class="nav-text text-muted me-auto" data-bs-toggle="tooltip" data-bs-placement="bottom" title="">1.8.2.9049</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">
@ -82,6 +82,11 @@
Get properties of an antibiotic
</a>
<a class="dropdown-item" href="../reference/av_property.html">
<span class="fa fa-capsules"></span>
Get properties of an antiviral agent
</a>
</div>
</li>
<li class="active nav-item">