mirror of
https://github.com/msberends/AMR.git
synced 2025-07-09 04:42:22 +02:00
(v1.7.1.9024) unit tests
This commit is contained in:
@ -5,11 +5,11 @@
|
||||
\alias{ab_name}
|
||||
\alias{set_ab_names}
|
||||
\alias{ATC}
|
||||
\alias{ab_atc}
|
||||
\alias{ab_cid}
|
||||
\alias{ab_synonyms}
|
||||
\alias{ab_tradenames}
|
||||
\alias{ab_group}
|
||||
\alias{ab_atc}
|
||||
\alias{ab_atc_group1}
|
||||
\alias{ab_atc_group2}
|
||||
\alias{ab_loinc}
|
||||
@ -28,8 +28,6 @@ set_ab_names(
|
||||
snake_case = property == "name"
|
||||
)
|
||||
|
||||
ab_atc(x, ...)
|
||||
|
||||
ab_cid(x, ...)
|
||||
|
||||
ab_synonyms(x, ...)
|
||||
@ -38,6 +36,8 @@ ab_tradenames(x, ...)
|
||||
|
||||
ab_group(x, language = get_locale(), ...)
|
||||
|
||||
ab_atc(x, only_first = FALSE, ...)
|
||||
|
||||
ab_atc_group1(x, language = get_locale(), ...)
|
||||
|
||||
ab_atc_group2(x, language = get_locale(), ...)
|
||||
@ -69,6 +69,8 @@ ab_property(x, property = "name", language = get_locale(), ...)
|
||||
|
||||
\item{snake_case}{a \link{logical} to indicate whether the names should be in so-called \href{https://en.wikipedia.org/wiki/Snake_case}{snake case}: in lower case and all spaces/slashes replaced with an underscore (\verb{_})}
|
||||
|
||||
\item{only_first}{a \link{logical} to indicate whether only the first ATC code must be returned, with giving preference to J0-codes (i.e., the antimicrobial drug group)}
|
||||
|
||||
\item{administration}{way of administration, either \code{"oral"} or \code{"iv"}}
|
||||
|
||||
\item{open}{browse the URL using \code{\link[utils:browseURL]{utils::browseURL()}}}
|
||||
@ -122,7 +124,7 @@ On our website \url{https://msberends.github.io/AMR/} you can find \href{https:/
|
||||
\examples{
|
||||
# all properties:
|
||||
ab_name("AMX") # "Amoxicillin"
|
||||
ab_atc("AMX") # J01CA04 (ATC code from the WHO)
|
||||
ab_atc("AMX") # "J01CA04" (ATC code from the WHO)
|
||||
ab_cid("AMX") # 33613 (Compound ID from PubChem)
|
||||
ab_synonyms("AMX") # a list with brand names of amoxicillin
|
||||
ab_tradenames("AMX") # same
|
||||
|
@ -33,63 +33,63 @@
|
||||
\alias{ureidopenicillins}
|
||||
\title{Antibiotic Selectors}
|
||||
\usage{
|
||||
ab_class(ab_class, only_rsi_columns = FALSE, only_treatable = TRUE)
|
||||
ab_class(ab_class, only_rsi_columns = FALSE, only_treatable = TRUE, ...)
|
||||
|
||||
ab_selector(filter, only_rsi_columns = FALSE, only_treatable = TRUE)
|
||||
ab_selector(filter, only_rsi_columns = FALSE, only_treatable = TRUE, ...)
|
||||
|
||||
administrable_per_os(only_rsi_columns = FALSE)
|
||||
administrable_per_os(only_rsi_columns = FALSE, ...)
|
||||
|
||||
administrable_iv(only_rsi_columns = FALSE)
|
||||
administrable_iv(only_rsi_columns = FALSE, ...)
|
||||
|
||||
aminoglycosides(only_rsi_columns = FALSE, only_treatable = TRUE)
|
||||
aminoglycosides(only_rsi_columns = FALSE, only_treatable = TRUE, ...)
|
||||
|
||||
aminopenicillins(only_rsi_columns = FALSE)
|
||||
aminopenicillins(only_rsi_columns = FALSE, ...)
|
||||
|
||||
antifungals(only_rsi_columns = FALSE)
|
||||
antifungals(only_rsi_columns = FALSE, ...)
|
||||
|
||||
antimycobacterials(only_rsi_columns = FALSE)
|
||||
antimycobacterials(only_rsi_columns = FALSE, ...)
|
||||
|
||||
betalactams(only_rsi_columns = FALSE, only_treatable = TRUE)
|
||||
betalactams(only_rsi_columns = FALSE, only_treatable = TRUE, ...)
|
||||
|
||||
carbapenems(only_rsi_columns = FALSE, only_treatable = TRUE)
|
||||
carbapenems(only_rsi_columns = FALSE, only_treatable = TRUE, ...)
|
||||
|
||||
cephalosporins(only_rsi_columns = FALSE)
|
||||
cephalosporins(only_rsi_columns = FALSE, ...)
|
||||
|
||||
cephalosporins_1st(only_rsi_columns = FALSE)
|
||||
cephalosporins_1st(only_rsi_columns = FALSE, ...)
|
||||
|
||||
cephalosporins_2nd(only_rsi_columns = FALSE)
|
||||
cephalosporins_2nd(only_rsi_columns = FALSE, ...)
|
||||
|
||||
cephalosporins_3rd(only_rsi_columns = FALSE)
|
||||
cephalosporins_3rd(only_rsi_columns = FALSE, ...)
|
||||
|
||||
cephalosporins_4th(only_rsi_columns = FALSE)
|
||||
cephalosporins_4th(only_rsi_columns = FALSE, ...)
|
||||
|
||||
cephalosporins_5th(only_rsi_columns = FALSE)
|
||||
cephalosporins_5th(only_rsi_columns = FALSE, ...)
|
||||
|
||||
fluoroquinolones(only_rsi_columns = FALSE)
|
||||
fluoroquinolones(only_rsi_columns = FALSE, ...)
|
||||
|
||||
glycopeptides(only_rsi_columns = FALSE)
|
||||
glycopeptides(only_rsi_columns = FALSE, ...)
|
||||
|
||||
lincosamides(only_rsi_columns = FALSE)
|
||||
lincosamides(only_rsi_columns = FALSE, ...)
|
||||
|
||||
lipoglycopeptides(only_rsi_columns = FALSE)
|
||||
lipoglycopeptides(only_rsi_columns = FALSE, ...)
|
||||
|
||||
macrolides(only_rsi_columns = FALSE)
|
||||
macrolides(only_rsi_columns = FALSE, ...)
|
||||
|
||||
oxazolidinones(only_rsi_columns = FALSE)
|
||||
oxazolidinones(only_rsi_columns = FALSE, ...)
|
||||
|
||||
penicillins(only_rsi_columns = FALSE)
|
||||
penicillins(only_rsi_columns = FALSE, ...)
|
||||
|
||||
polymyxins(only_rsi_columns = FALSE, only_treatable = TRUE)
|
||||
polymyxins(only_rsi_columns = FALSE, only_treatable = TRUE, ...)
|
||||
|
||||
streptogramins(only_rsi_columns = FALSE)
|
||||
streptogramins(only_rsi_columns = FALSE, ...)
|
||||
|
||||
quinolones(only_rsi_columns = FALSE)
|
||||
quinolones(only_rsi_columns = FALSE, ...)
|
||||
|
||||
tetracyclines(only_rsi_columns = FALSE)
|
||||
tetracyclines(only_rsi_columns = FALSE, ...)
|
||||
|
||||
trimethoprims(only_rsi_columns = FALSE)
|
||||
trimethoprims(only_rsi_columns = FALSE, ...)
|
||||
|
||||
ureidopenicillins(only_rsi_columns = FALSE)
|
||||
ureidopenicillins(only_rsi_columns = FALSE, ...)
|
||||
}
|
||||
\arguments{
|
||||
\item{ab_class}{an antimicrobial class, such as \code{"carbapenems"}. The columns \code{group}, \code{atc_group1} and \code{atc_group2} of the \link{antibiotics} data set will be searched (case-insensitive) for this value.}
|
||||
@ -98,6 +98,8 @@ ureidopenicillins(only_rsi_columns = FALSE)
|
||||
|
||||
\item{only_treatable}{a \link{logical} to indicate whether agents that are only for laboratory tests should be excluded (defaults to \code{TRUE}), such as gentamicin-high (\code{GEH}) and imipenem/EDTA (\code{IPE})}
|
||||
|
||||
\item{...}{ignored, only in place to allow future extensions}
|
||||
|
||||
\item{filter}{an \link{expression} to be evaluated in the \link{antibiotics} data set, such as \code{name \%like\% "trim"}}
|
||||
}
|
||||
\value{
|
||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user