mirror of https://github.com/msberends/AMR.git
187 lines
14 KiB
HTML
187 lines
14 KiB
HTML
<!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.0">
|
||
<title>Introduction to the AMR package • AMR</title>
|
||
<!-- jquery --><script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script><!-- Bootstrap --><link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha256-916EbMg70RQy9LHiGkXzG8hSg9EdNy97GazNG/aiY1w=" crossorigin="anonymous">
|
||
<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha256-U5ZEeKfGNOja007MMD3YBI0A3OSZOQbeG6z2f2Y0hu8=" crossorigin="anonymous"></script><!-- Font Awesome icons --><link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" integrity="sha256-eZrrJcwDc/3uDhsdt61sL2oOBY362qM3lon1gyExkL0=" crossorigin="anonymous">
|
||
<!-- clipboard.js --><script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.4/clipboard.min.js" integrity="sha256-FiZwavyI2V6+EXO1U+xzLG3IKldpiTFf3153ea9zikQ=" crossorigin="anonymous"></script><!-- sticky kit --><script src="https://cdnjs.cloudflare.com/ajax/libs/sticky-kit/1.1.3/sticky-kit.min.js" integrity="sha256-c4Rlo1ZozqTPE2RLuvbusY3+SU1pQaJC0TjuhygMipw=" crossorigin="anonymous"></script><!-- pkgdown --><link href="../pkgdown.css" rel="stylesheet">
|
||
<script src="../pkgdown.js"></script><meta property="og:title" content="Introduction to the AMR package">
|
||
<meta property="og:description" content="">
|
||
<meta name="twitter:card" content="summary">
|
||
<!-- 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>
|
||
<div class="container template-article">
|
||
<header><div class="navbar navbar-default navbar-fixed-top" role="navigation">
|
||
<div class="container">
|
||
<div class="navbar-header">
|
||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false">
|
||
<span class="sr-only">Toggle navigation</span>
|
||
<span class="icon-bar"></span>
|
||
<span class="icon-bar"></span>
|
||
<span class="icon-bar"></span>
|
||
</button>
|
||
<span class="navbar-brand">
|
||
<a class="navbar-link" href="../index.html">AMR</a>
|
||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9007</span>
|
||
</span>
|
||
</div>
|
||
|
||
<div id="navbar" class="navbar-collapse collapse">
|
||
<ul class="nav navbar-nav">
|
||
<li>
|
||
<a href="../index.html">
|
||
<span class="fa fa-home fa-lg"></span>
|
||
|
||
</a>
|
||
</li>
|
||
<li>
|
||
<a href="../articles/AMR.html">Get started</a>
|
||
</li>
|
||
<li>
|
||
<a href="../reference/index.html">Reference</a>
|
||
</li>
|
||
<li class="dropdown">
|
||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">
|
||
Articles
|
||
|
||
<span class="caret"></span>
|
||
</a>
|
||
<ul class="dropdown-menu" role="menu">
|
||
<li>
|
||
<a href="../articles/freq.html">Creating Frequency Tables</a>
|
||
</li>
|
||
</ul>
|
||
</li>
|
||
<li>
|
||
<a href="../news/index.html">Changelog</a>
|
||
</li>
|
||
</ul>
|
||
<ul class="nav navbar-nav navbar-right"></ul>
|
||
</div>
|
||
<!--/.nav-collapse -->
|
||
</div>
|
||
<!--/.container -->
|
||
</div>
|
||
<!--/.navbar -->
|
||
|
||
|
||
</header><div class="row">
|
||
<div class="col-md-9 contents">
|
||
<div class="page-header toc-ignore">
|
||
<h1>Introduction to the AMR package</h1>
|
||
<h4 class="author">Matthijs S. Berends</h4>
|
||
|
||
|
||
|
||
<div class="hidden name"><code>AMR.Rmd</code></div>
|
||
|
||
</div>
|
||
|
||
|
||
|
||
<p>This R package was intended <strong>to make microbial epidemiology easier</strong>. Most functions contain extensive help pages to get started.</p>
|
||
<p>The <code>AMR</code> package basically does four important things:</p>
|
||
<ol style="list-style-type: decimal">
|
||
<li>It <strong>cleanses existing data</strong>, by transforming it to reproducible and profound <em>classes</em>, making the most efficient use of R. These functions all use artificial intelligence to guess results that you would expect:</li>
|
||
</ol>
|
||
<ul>
|
||
<li>Use <code>as.mo</code> to get an ID of a microorganism. The IDs are human readable for the trained eye - the ID of <em>Klebsiella pneumoniae</em> is “B_KLBSL_PNE” (B stands for Bacteria) and the ID of <em>S. aureus</em> is “B_STPHY_AUR”. The function takes almost any text as input that looks like the name or code of a microorganism like “E. coli”, “esco” and “esccol”. Even <code><a href="../reference/as.mo.html">as.mo("MRSA")</a></code> will return the ID of <em>S. aureus</em>. Moreover, it can group all coagulase negative and positive <em>Staphylococci</em>, and can transform <em>Streptococci</em> into Lancefield groups. To find bacteria based on your input, it uses Artificial Intelligence to look up values in the included ITIS data, consisting of more than 18,000 microorganisms.</li>
|
||
<li>Use <code>as.rsi</code> to transform values to valid antimicrobial results. It produces just S, I or R based on your input and warns about invalid values. Even values like “<=0.002; S” (combined MIC/RSI) will result in “S”.</li>
|
||
<li>Use <code>as.mic</code> to cleanse your MIC values. It produces a so-called factor (called <em>ordinal</em> in SPSS) with valid MIC values as levels. A value like “<=0.002; S” (combined MIC/RSI) will result in “<=0.002”.</li>
|
||
<li>Use <code>as.atc</code> to get the ATC code of an antibiotic as defined by the WHO. This package contains a database with most LIS codes, official names, DDDs and even trade names of antibiotics. For example, the values “Furabid”, “Furadantin”, “nitro” all return the ATC code of Nitrofurantoine.</li>
|
||
</ul>
|
||
<ol start="2" style="list-style-type: decimal">
|
||
<li>It <strong>enhances existing data</strong> and <strong>adds new data</strong> from data sets included in this package.</li>
|
||
</ol>
|
||
<ul>
|
||
<li>Use <code>EUCAST_rules</code> to apply <a href="http://www.eucast.org/expert_rules_and_intrinsic_resistance/">EUCAST expert rules to isolates</a>.</li>
|
||
<li>Use <code>first_isolate</code> to identify the first isolates of every patient <a href="https://clsi.org/standards/products/microbiology/documents/m39/">using guidelines from the CLSI</a> (Clinical and Laboratory Standards Institute).
|
||
<ul>
|
||
<li>You can also identify first <em>weighted</em> isolates of every patient, an adjusted version of the CLSI guideline. This takes into account key antibiotics of every strain and compares them.</li>
|
||
</ul>
|
||
</li>
|
||
<li>Use <code>MDRO</code> (abbreviation of Multi Drug Resistant Organisms) to check your isolates for exceptional resistance with country-specific guidelines or EUCAST rules. Currently, national guidelines for Germany and the Netherlands are supported.</li>
|
||
<li>The data set <code>microorganisms</code> contains the complete taxonomic tree of more than 18,000 microorganisms (bacteria, fungi/yeasts and protozoa). Furthermore, the colloquial name and Gram stain are available, which enables resistance analysis of e.g. different antibiotics per Gram stain. The package also contains functions to look up values in this data set like <code>mo_genus</code>, <code>mo_family</code>, <code>mo_gramstain</code> or even <code>mo_phylum</code>. As they use <code>as.mo</code> internally, they also use artificial intelligence. For example, <code><a href="../reference/mo_property.html">mo_genus("MRSA")</a></code> and <code><a href="../reference/mo_property.html">mo_genus("S. aureus")</a></code> will both return <code>"Staphylococcus"</code>. They also come with support for German, Dutch, French, Italian, Spanish and Portuguese. These functions can be used to add new variables to your data.</li>
|
||
<li>The data set <code>antibiotics</code> contains the ATC code, LIS codes, official name, trivial name and DDD of both oral and parenteral administration. It also contains a total of 298 trade names. Use functions like <code>ab_name</code> and <code>ab_tradenames</code> to look up values. The <code>ab_*</code> functions use <code>as.atc</code> internally so they support AI to guess your expected result. For example, <code><a href="../reference/ab_property.html">ab_name("Fluclox")</a></code>, <code><a href="../reference/ab_property.html">ab_name("Floxapen")</a></code> and <code><a href="../reference/ab_property.html">ab_name("J01CF05")</a></code> will all return <code>"Flucloxacillin"</code>. These functions can again be used to add new variables to your data.</li>
|
||
</ul>
|
||
<ol start="3" style="list-style-type: decimal">
|
||
<li>It <strong>analyses the data</strong> with convenient functions that use well-known methods.</li>
|
||
</ol>
|
||
<ul>
|
||
<li>Calculate the resistance (and even co-resistance) of microbial isolates with the <code>portion_R</code>, <code>portion_IR</code>, <code>portion_I</code>, <code>portion_SI</code> and <code>portion_S</code> functions. Similarly, the <em>number</em> of isolates can be determined with the <code>count_R</code>, <code>count_IR</code>, <code>count_I</code>, <code>count_SI</code> and <code>count_S</code> functions. All these functions can be used <a href="https://dplyr.tidyverse.org/#usage">with the <code>dplyr</code> package</a> (e.g. in conjunction with <a href="https://dplyr.tidyverse.org/reference/summarise.html"><code>summarise</code></a>)</li>
|
||
<li>Plot AMR results with <code>geom_rsi</code>, a function made for the <code>ggplot2</code> package</li>
|
||
<li>Predict antimicrobial resistance for the nextcoming years using logistic regression models with the <code>resistance_predict</code> function</li>
|
||
<li>Conduct descriptive statistics to enhance base R: calculate kurtosis, skewness and create frequency tables</li>
|
||
</ul>
|
||
<ol start="4" style="list-style-type: decimal">
|
||
<li>It <strong>teaches the user</strong> how to use all the above actions.</li>
|
||
</ol>
|
||
<ul>
|
||
<li>The package contains extensive help pages with many examples.</li>
|
||
<li>It also contains an example data set called <code>septic_patients</code>. This data set contains:
|
||
<ul>
|
||
<li>2,000 blood culture isolates from anonymised septic patients between 2001 and 2017 in the Northern Netherlands</li>
|
||
<li>Results of 40 antibiotics (each antibiotic in its own column) with a total of 38,414 antimicrobial results</li>
|
||
<li>Real and genuine data</li>
|
||
</ul>
|
||
</li>
|
||
</ul>
|
||
<div id="itis" class="section level3">
|
||
<h3 class="hasAnchor">
|
||
<a href="#itis" class="anchor"></a>ITIS</h3>
|
||
<p>This package contains the <strong>complete microbial taxonomic data</strong> (with all seven taxonomic ranks - from subkingdom to subspecies) from the publicly available Integrated Taxonomic Information System (ITIS, <a href="https://www.itis.gov" class="uri">https://www.itis.gov</a>).</p>
|
||
<p>All (sub)species from the taxonomic kingdoms Bacteria, Fungi and Protozoa are included in this package, as well as all previously accepted names known to ITIS. Furthermore, the responsible authors and year of publication are available. This allows users to use authoritative taxonomic information for their data analysis on any microorganism, not only human pathogens.</p>
|
||
<p>ITIS is a partnership of U.S., Canadian, and Mexican agencies and taxonomic specialists.</p>
|
||
<p><strong>Get a note when a species was renamed</strong></p>
|
||
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw"><a href="../reference/mo_property.html">mo_shortname</a></span>(<span class="st">"Chlamydia psittaci"</span>)
|
||
<span class="co"># Note: 'Chlamydia psittaci' (Page, 1968) was renamed 'Chlamydophila psittaci' (Everett et al., 1999)</span>
|
||
<span class="co"># [1] "C. psittaci"</span></code></pre></div>
|
||
<p><strong>Get any property from the entire taxonomic tree for all included species</strong></p>
|
||
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw"><a href="../reference/mo_property.html">mo_class</a></span>(<span class="st">"E. coli"</span>)
|
||
<span class="co"># [1] "Gammaproteobacteria"</span>
|
||
|
||
<span class="kw"><a href="../reference/mo_property.html">mo_family</a></span>(<span class="st">"E. coli"</span>)
|
||
<span class="co"># [1] "Enterobacteriaceae"</span>
|
||
|
||
<span class="kw"><a href="../reference/mo_property.html">mo_ref</a></span>(<span class="st">"E. coli"</span>)
|
||
<span class="co"># [1] "Castellani and Chalmers, 1919"</span></code></pre></div>
|
||
<p><strong>Do not get mistaken - the package only includes microorganisms</strong></p>
|
||
<div class="sourceCode"><pre class="sourceCode r"><code class="sourceCode r"><span class="kw"><a href="../reference/mo_property.html">mo_phylum</a></span>(<span class="st">"C. elegans"</span>)
|
||
<span class="co"># [1] "Cyanobacteria" # Bacteria?!</span>
|
||
<span class="kw"><a href="../reference/mo_property.html">mo_fullname</a></span>(<span class="st">"C. elegans"</span>)
|
||
<span class="co"># [1] "Chroococcus limneticus elegans" # Because a microorganism was found </span></code></pre></div>
|
||
<hr>
|
||
<p>AMR, (c) 2018, <a href="https://gitlab.com/msberends/AMR" class="uri">https://gitlab.com/msberends/AMR</a></p>
|
||
<p>Licensed under the <a href="https://github.com/msberends/AMR/blob/master/LICENSE">GNU General Public License v2.0</a>.</p>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="col-md-3 hidden-xs hidden-sm" id="sidebar">
|
||
</div>
|
||
|
||
</div>
|
||
|
||
|
||
<footer><div class="copyright">
|
||
<p>Developed by Matthijs S. Berends, Christian F. Luz.</p>
|
||
</div>
|
||
|
||
<div class="pkgdown">
|
||
<p>Site built with <a href="https://pkgdown.r-lib.org/">pkgdown</a> 1.3.0.</p>
|
||
</div>
|
||
</footer>
|
||
</div>
|
||
|
||
|
||
|
||
</body>
|
||
</html>
|