mirror of
https://github.com/msberends/AMR.git
synced 2024-12-25 06:46:11 +01:00
less deps
This commit is contained in:
parent
a2d3ea280a
commit
e76961a66b
12
DESCRIPTION
12
DESCRIPTION
@ -1,5 +1,5 @@
|
||||
Package: AMR
|
||||
Version: 0.5.0.9012
|
||||
Version: 0.5.0.9013
|
||||
Date: 2019-01-27
|
||||
Title: Antimicrobial Resistance Analysis
|
||||
Authors@R: c(
|
||||
@ -45,23 +45,23 @@ Depends:
|
||||
R (>= 3.1.0)
|
||||
Imports:
|
||||
backports,
|
||||
curl,
|
||||
crayon (>= 1.3.0),
|
||||
data.table (>= 1.9.0),
|
||||
dplyr (>= 0.7.0),
|
||||
hms,
|
||||
knitr (>= 1.0.0),
|
||||
rlang (>= 0.2.0),
|
||||
rvest (>= 0.3.2),
|
||||
tidyr (>= 0.7.0),
|
||||
xml2 (>= 1.0.0)
|
||||
tidyr (>= 0.7.0)
|
||||
Suggests:
|
||||
covr (>= 3.0.1),
|
||||
curl,
|
||||
ggplot2,
|
||||
readxl,
|
||||
rmarkdown,
|
||||
rstudioapi,
|
||||
testthat (>= 1.0.2)
|
||||
rvest (>= 0.3.2),
|
||||
testthat (>= 1.0.2),
|
||||
xml2 (>= 1.0.0)
|
||||
VignetteBuilder: knitr
|
||||
URL: https://msberends.gitlab.io/AMR, https://gitlab.com/msberends/AMR
|
||||
BugReports: https://gitlab.com/msberends/AMR/issues
|
||||
|
@ -19,7 +19,7 @@
|
||||
# Visit our website for more info: https://msberends.gitab.io/AMR. #
|
||||
# ==================================================================== #
|
||||
|
||||
#' Properties of an ATC code
|
||||
#' Get ATC properties from WHOCC website
|
||||
#'
|
||||
#' Gets data from the WHO to determine properties of an ATC (e.g. an antibiotic) like name, defined daily dose (DDD) or standard unit. \cr \strong{This function requires an internet connection.}
|
||||
#' @param atc_code a character or character vector with ATC code(s) of antibiotic(s)
|
||||
@ -78,6 +78,10 @@ atc_online_property <- function(atc_code,
|
||||
administration = 'O',
|
||||
url = 'https://www.whocc.no/atc_ddd_index/?code=%s&showdescription=no') {
|
||||
|
||||
if (!all(c("curl", "rvest", "xml2") %in% rownames(installed.packages()))) {
|
||||
stop("Packages 'xml2', 'rvest' and 'curl' are required for this function")
|
||||
}
|
||||
|
||||
# check active network interface, from https://stackoverflow.com/a/5078002/4575331
|
||||
has_internet <- function(url) {
|
||||
# extract host from given url
|
||||
|
@ -19,7 +19,7 @@
|
||||
# Visit our website for more info: https://msberends.gitab.io/AMR. #
|
||||
# ==================================================================== #
|
||||
|
||||
#' AMR bar plots with \code{ggplot}
|
||||
#' AMR plots with \code{ggplot2}
|
||||
#'
|
||||
#' Use these functions to create bar plots for antimicrobial resistance analysis. All functions rely on internal \code{\link[ggplot2]{ggplot}} functions.
|
||||
#' @param data a \code{data.frame} with column(s) of class \code{"rsi"} (see \code{\link{as.rsi}})
|
||||
|
@ -78,7 +78,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -78,7 +78,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -78,7 +78,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -42,7 +42,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -78,7 +78,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -6,7 +6,7 @@
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
<title>Properties of an ATC code — atc_online_property • AMR (for R)</title>
|
||||
<title>Get ATC properties from WHOCC website — atc_online_property • AMR (for R)</title>
|
||||
|
||||
<!-- favicons -->
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="../favicon-16x16.png">
|
||||
@ -45,7 +45,7 @@
|
||||
|
||||
<link href="../extra.css" rel="stylesheet">
|
||||
<script src="../extra.js"></script>
|
||||
<meta property="og:title" content="Properties of an ATC code — atc_online_property" />
|
||||
<meta property="og:title" content="Get ATC properties from WHOCC website — atc_online_property" />
|
||||
|
||||
<meta property="og:description" content="Gets data from the WHO to determine properties of an ATC (e.g. an antibiotic) like name, defined daily dose (DDD) or standard unit. This function requires an internet connection." />
|
||||
|
||||
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
@ -216,7 +216,7 @@
|
||||
<div class="row">
|
||||
<div class="col-md-9 contents">
|
||||
<div class="page-header">
|
||||
<h1>Properties of an ATC code</h1>
|
||||
<h1>Get ATC properties from WHOCC website</h1>
|
||||
|
||||
<div class="hidden name"><code>atc_online.Rd</code></div>
|
||||
</div>
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -6,7 +6,7 @@
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
<title>AMR bar plots with <code>ggplot</code> — ggplot_rsi • AMR (for R)</title>
|
||||
<title>AMR plots with <code>ggplot2</code> — ggplot_rsi • AMR (for R)</title>
|
||||
|
||||
<!-- favicons -->
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="../favicon-16x16.png">
|
||||
@ -45,7 +45,7 @@
|
||||
|
||||
<link href="../extra.css" rel="stylesheet">
|
||||
<script src="../extra.js"></script>
|
||||
<meta property="og:title" content="AMR bar plots with <code>ggplot</code> — ggplot_rsi" />
|
||||
<meta property="og:title" content="AMR plots with <code>ggplot2</code> — ggplot_rsi" />
|
||||
|
||||
<meta property="og:description" content="Use these functions to create bar plots for antimicrobial resistance analysis. All functions rely on internal ggplot functions." />
|
||||
|
||||
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
@ -216,7 +216,7 @@
|
||||
<div class="row">
|
||||
<div class="col-md-9 contents">
|
||||
<div class="page-header">
|
||||
<h1>AMR bar plots with <code>ggplot</code></h1>
|
||||
<h1>AMR plots with <code>ggplot2</code></h1>
|
||||
|
||||
<div class="hidden name"><code>ggplot_rsi.Rd</code></div>
|
||||
</div>
|
||||
|
@ -78,7 +78,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
@ -349,7 +349,7 @@
|
||||
<td>
|
||||
<p><code><a href="atc_online.html">atc_online_property()</a></code> <code><a href="atc_online.html">atc_online_groups()</a></code> <code><a href="atc_online.html">atc_online_ddd()</a></code> </p>
|
||||
</td>
|
||||
<td><p>Properties of an ATC code</p></td>
|
||||
<td><p>Get ATC properties from WHOCC website</p></td>
|
||||
</tr><tr>
|
||||
|
||||
<td>
|
||||
@ -417,7 +417,7 @@
|
||||
<td>
|
||||
<p><code><a href="ggplot_rsi.html">ggplot_rsi()</a></code> <code><a href="ggplot_rsi.html">geom_rsi()</a></code> <code><a href="ggplot_rsi.html">facet_rsi()</a></code> <code><a href="ggplot_rsi.html">scale_y_percent()</a></code> <code><a href="ggplot_rsi.html">scale_rsi_colours()</a></code> <code><a href="ggplot_rsi.html">theme_rsi()</a></code> <code><a href="ggplot_rsi.html">labels_rsi_count()</a></code> </p>
|
||||
</td>
|
||||
<td><p>AMR bar plots with <code>ggplot</code></p></td>
|
||||
<td><p>AMR plots with <code>ggplot2</code></p></td>
|
||||
</tr><tr>
|
||||
|
||||
<td>
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -80,7 +80,7 @@
|
||||
</button>
|
||||
<span class="navbar-brand">
|
||||
<a class="navbar-link" href="../index.html">AMR (for R)</a>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9012</span>
|
||||
<span class="version label label-default" data-toggle="tooltip" data-placement="bottom" title="Released version">0.5.0.9013</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
\alias{atc_online_property}
|
||||
\alias{atc_online_groups}
|
||||
\alias{atc_online_ddd}
|
||||
\title{Properties of an ATC code}
|
||||
\title{Get ATC properties from WHOCC website}
|
||||
\source{
|
||||
\url{https://www.whocc.no/atc_ddd_alterations__cumulative/ddd_alterations/abbrevations/}
|
||||
}
|
||||
|
@ -8,7 +8,7 @@
|
||||
\alias{scale_rsi_colours}
|
||||
\alias{theme_rsi}
|
||||
\alias{labels_rsi_count}
|
||||
\title{AMR bar plots with \code{ggplot}}
|
||||
\title{AMR plots with \code{ggplot2}}
|
||||
\usage{
|
||||
ggplot_rsi(data, position = NULL, x = "Antibiotic",
|
||||
fill = "Interpretation", facet = NULL, breaks = seq(0, 1, 0.1),
|
||||
|
Loading…
Reference in New Issue
Block a user