mirror of
https://github.com/msberends/AMR.git
synced 2025-07-11 12:22:01 +02:00
(v1.7.1.9063) not_intrinsic_resistant
This commit is contained in:
@ -1,11 +1,9 @@
|
||||
% Generated by roxygen2: do not edit by hand
|
||||
% Please edit documentation in R/ab_class_selectors.R
|
||||
% Please edit documentation in R/ab_selectors.R
|
||||
\name{antibiotic_class_selectors}
|
||||
\alias{antibiotic_class_selectors}
|
||||
\alias{ab_class}
|
||||
\alias{ab_selector}
|
||||
\alias{administrable_per_os}
|
||||
\alias{administrable_iv}
|
||||
\alias{aminoglycosides}
|
||||
\alias{aminopenicillins}
|
||||
\alias{antifungals}
|
||||
@ -31,16 +29,15 @@
|
||||
\alias{tetracyclines}
|
||||
\alias{trimethoprims}
|
||||
\alias{ureidopenicillins}
|
||||
\alias{administrable_per_os}
|
||||
\alias{administrable_iv}
|
||||
\alias{not_intrinsic_resistant}
|
||||
\title{Antibiotic Selectors}
|
||||
\usage{
|
||||
ab_class(ab_class, 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_iv(only_rsi_columns = FALSE, ...)
|
||||
|
||||
aminoglycosides(only_rsi_columns = FALSE, only_treatable = TRUE, ...)
|
||||
|
||||
aminopenicillins(only_rsi_columns = FALSE, ...)
|
||||
@ -90,6 +87,17 @@ tetracyclines(only_rsi_columns = FALSE, ...)
|
||||
trimethoprims(only_rsi_columns = FALSE, ...)
|
||||
|
||||
ureidopenicillins(only_rsi_columns = FALSE, ...)
|
||||
|
||||
administrable_per_os(only_rsi_columns = FALSE, ...)
|
||||
|
||||
administrable_iv(only_rsi_columns = FALSE, ...)
|
||||
|
||||
not_intrinsic_resistant(
|
||||
only_rsi_columns = FALSE,
|
||||
col_mo = NULL,
|
||||
version_expertrules = 3.3,
|
||||
...
|
||||
)
|
||||
}
|
||||
\arguments{
|
||||
\item{ab_class}{an antimicrobial class or a part of it, such as \code{"carba"} and \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.}
|
||||
@ -101,6 +109,10 @@ ureidopenicillins(only_rsi_columns = FALSE, ...)
|
||||
\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"}}
|
||||
|
||||
\item{col_mo}{column name of the IDs of the microorganisms (see \code{\link[=as.mo]{as.mo()}}), defaults to the first column of class \code{\link{mo}}. Values will be coerced using \code{\link[=as.mo]{as.mo()}}.}
|
||||
|
||||
\item{version_expertrules}{the version number to use for the EUCAST Expert Rules and Intrinsic Resistance guideline. Can be either "3.3", "3.2" or "3.1".}
|
||||
}
|
||||
\value{
|
||||
(internally) a \link{character} vector of column names, with additional class \code{"ab_selector"}
|
||||
@ -118,6 +130,8 @@ The \code{\link[=ab_class]{ab_class()}} function can be used to filter/select on
|
||||
The \code{\link[=ab_selector]{ab_selector()}} function can be used to internally filter the \link{antibiotics} data set on any results, see \emph{Examples}. It allows for filtering on a (part of) a certain name, and/or a group name or even a minimum of DDDs for oral treatment. This function yields the highest flexibility, but is also the least user-friendly, since it requires a hard-coded filter to set.
|
||||
|
||||
The \code{\link[=administrable_per_os]{administrable_per_os()}} and \code{\link[=administrable_iv]{administrable_iv()}} functions also rely on the \link{antibiotics} data set - antibiotic columns will be matched where a DDD (defined daily dose) for resp. oral and IV treatment is available in the \link{antibiotics} data set.
|
||||
|
||||
The \code{\link[=not_intrinsic_resistant]{not_intrinsic_resistant()}} function can be used to only select antibiotic columns that pose no intrinsic resistance for the microorganisms in the data set. For example, if a data set contains only microorganism codes or names of \emph{E. coli} and \emph{K. pneumoniae} and contains a column "vancomycin", this column will be removed (or rather, unselected) using this function. It currently applies \href{https://www.eucast.org/expert_rules_and_intrinsic_resistance/}{'EUCAST Expert Rules' and 'EUCAST Intrinsic Resistance and Unusual Phenotypes' v3.3} (2021) to determine intrinsic resistance, using the \code{\link[=eucast_rules]{eucast_rules()}} function internally. Because of this determination, this function is quite slow in terms of performance.
|
||||
}
|
||||
\section{Full list of supported (antibiotic) classes}{
|
||||
|
||||
@ -221,6 +235,12 @@ if (require("dplyr")) {
|
||||
# You can combine selectors with '&' to be more specific:
|
||||
example_isolates \%>\%
|
||||
select(penicillins() & administrable_per_os())
|
||||
|
||||
# get AMR for only drugs that matter - no intrinsic resistance:
|
||||
example_isolates \%>\%
|
||||
filter(mo_genus() \%in\% c("Escherichia", "Klebsiella")) \%>\%
|
||||
group_by(hospital_id) \%>\%
|
||||
summarise(across(not_intrinsic_resistant(), resistance))
|
||||
|
||||
# get susceptibility for antibiotics whose name contains "trim":
|
||||
example_isolates \%>\%
|
||||
|
@ -49,7 +49,7 @@ eucast_dosage(ab, administration = "iv", version_breakpoints = 11)
|
||||
|
||||
\item{version_expertrules}{the version number to use for the EUCAST Expert Rules and Intrinsic Resistance guideline. Can be either "3.3", "3.2" or "3.1".}
|
||||
|
||||
\item{ampc_cephalosporin_resistance}{a \link{character} value that should be applied to cefotaxime, ceftriaxone and ceftazidime for AmpC de-repressed cephalosporin-resistant mutants, defaults to \code{NA}. Currently only works when \code{version_expertrules} is \code{3.2}; '\emph{EUCAST Expert Rules v3.2 on Enterobacterales}' states that results of cefotaxime, ceftriaxone and ceftazidime should be reported with a note, or results should be suppressed (emptied) for these three agents. A value of \code{NA} (the default) for this argument will remove results for these three agents, while e.g. a value of \code{"R"} will make the results for these agents resistant. Use \code{NULL} or \code{FALSE} to not alter results for these three agents of AmpC de-repressed cephalosporin-resistant mutants. Using \code{TRUE} is equal to using \code{"R"}. \cr For \emph{EUCAST Expert Rules} v3.2, this rule applies to: \emph{Citrobacter braakii}, \emph{Citrobacter freundii}, \emph{Citrobacter gillenii}, \emph{Citrobacter murliniae}, \emph{Citrobacter rodenticum}, \emph{Citrobacter sedlakii}, \emph{Citrobacter werkmanii}, \emph{Citrobacter youngae}, \emph{Enterobacter}, \emph{Hafnia alvei}, \emph{Klebsiella aerogenes}, \emph{Morganella morganii}, \emph{Providencia} and \emph{Serratia}.}
|
||||
\item{ampc_cephalosporin_resistance}{a \link{character} value that should be applied to cefotaxime, ceftriaxone and ceftazidime for AmpC de-repressed cephalosporin-resistant mutants, defaults to \code{NA}. Currently only works when \code{version_expertrules} is \code{3.2} and higher; these version of '\emph{EUCAST Expert Rules on Enterobacterales}' state that results of cefotaxime, ceftriaxone and ceftazidime should be reported with a note, or results should be suppressed (emptied) for these three agents. A value of \code{NA} (the default) for this argument will remove results for these three agents, while e.g. a value of \code{"R"} will make the results for these agents resistant. Use \code{NULL} or \code{FALSE} to not alter results for these three agents of AmpC de-repressed cephalosporin-resistant mutants. Using \code{TRUE} is equal to using \code{"R"}. \cr For \emph{EUCAST Expert Rules} v3.2, this rule applies to: \emph{Citrobacter braakii}, \emph{Citrobacter freundii}, \emph{Citrobacter gillenii}, \emph{Citrobacter murliniae}, \emph{Citrobacter rodenticum}, \emph{Citrobacter sedlakii}, \emph{Citrobacter werkmanii}, \emph{Citrobacter youngae}, \emph{Enterobacter}, \emph{Hafnia alvei}, \emph{Klebsiella aerogenes}, \emph{Morganella morganii}, \emph{Providencia} and \emph{Serratia}.}
|
||||
|
||||
\item{only_rsi_columns}{a \link{logical} to indicate whether only antibiotic columns must be detected that were transformed to class \verb{<rsi>} (see \code{\link[=as.rsi]{as.rsi()}}) on beforehand (defaults to \code{FALSE})}
|
||||
|
||||
|
@ -63,5 +63,5 @@ mo_matching_score(x = "E. coli",
|
||||
n = c("Escherichia coli", "Entamoeba coli"))
|
||||
}
|
||||
\author{
|
||||
Matthijs S. Berends
|
||||
Dr. Matthijs Berends
|
||||
}
|
||||
|
@ -24,6 +24,7 @@
|
||||
\alias{mo_ref}
|
||||
\alias{mo_authors}
|
||||
\alias{mo_year}
|
||||
\alias{mo_lpsn}
|
||||
\alias{mo_rank}
|
||||
\alias{mo_taxonomy}
|
||||
\alias{mo_synonyms}
|
||||
@ -75,6 +76,8 @@ mo_authors(x, language = get_locale(), ...)
|
||||
|
||||
mo_year(x, language = get_locale(), ...)
|
||||
|
||||
mo_lpsn(x, language = get_locale(), ...)
|
||||
|
||||
mo_rank(x, language = get_locale(), ...)
|
||||
|
||||
mo_taxonomy(x, language = get_locale(), ...)
|
||||
@ -226,6 +229,7 @@ mo_synonyms("E. coli") # get previously accepted taxonomic names
|
||||
mo_ref("E. coli") # "Castellani et al., 1919"
|
||||
mo_authors("E. coli") # "Castellani et al."
|
||||
mo_year("E. coli") # 1919
|
||||
mo_lpsn("E. coli") # 776057 (LPSN record ID)
|
||||
|
||||
# abbreviations known in the field -----------------------------------------
|
||||
mo_genus("MRSA") # "Staphylococcus"
|
||||
|
Reference in New Issue
Block a user