eucast_rules: Apply EUCAST Rules

Description Usage Arguments Details Value Antibiotics Stable Lifecycle Reference Data Publicly Available Read more on Our Website! Source Examples

View source: R/eucast_rules.R

Description

Apply rules for clinical breakpoints and intrinsic resistance as defined by the European Committee on Antimicrobial Susceptibility Testing (EUCAST, https://eucast.org), see Source. Use eucast_dosage() to get a data.frame with advised dosages of a certain bug-drug combination, which is based on the dosage data set.

To improve the interpretation of the antibiogram before EUCAST rules are applied, some non-EUCAST rules can applied at default, see Details.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
eucast_rules(
  x,
  col_mo = NULL,
  info = interactive(),
  rules = getOption("AMR_eucastrules", default = c("breakpoints", "expert")),
  verbose = FALSE,
  version_breakpoints = 11,
  version_expertrules = 3.2,
  ampc_cephalosporin_resistance = NA,
  only_rsi_columns = FALSE,
  custom_rules = NULL,
  ...
)

eucast_dosage(ab, administration = "iv", version_breakpoints = 11)

Arguments

x

data with antibiotic columns, such as amox, AMX and AMC

col_mo

column name of the IDs of the microorganisms (see as.mo()), defaults to the first column of class mo. Values will be coerced using as.mo().

info

a logical to indicate whether progress should be printed to the console, defaults to only print while in interactive sessions

rules

a character vector that specifies which rules should be applied. Must be one or more of "breakpoints", "expert", "other", "custom", "all", and defaults to c("breakpoints", "expert"). The default value can be set to another value, e.g. using options(AMR_eucastrules = "all"). If using "custom", be sure to fill in argument custom_rules too. Custom rules can be created with custom_eucast_rules().

verbose

a logical to turn Verbose mode on and off (default is off). In Verbose mode, the function does not apply rules to the data, but instead returns a data set in logbook form with extensive info about which rows and columns would be effected and in which way. Using Verbose mode takes a lot more time.

version_breakpoints

the version number to use for the EUCAST Clinical Breakpoints guideline. Can be either "11.0" or "10.0".

version_expertrules

the version number to use for the EUCAST Expert Rules and Intrinsic Resistance guideline. Can be either "3.2" or "3.1".

ampc_cephalosporin_resistance

a character value that should be applied to cefotaxime, ceftriaxone and ceftazidime for AmpC de-repressed cephalosporin-resistant mutants, defaults to NA. Currently only works when version_expertrules is 3.2; '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 NA (the default) for this argument will remove results for these three agents, while e.g. a value of "R" will make the results for these agents resistant. Use NULL or FALSE to not alter results for these three agents of AmpC de-repressed cephalosporin-resistant mutants. Using TRUE is equal to using "R".
For EUCAST Expert Rules v3.2, this rule applies to: Citrobacter braakii, Citrobacter freundii, Citrobacter gillenii, Citrobacter murliniae, Citrobacter rodenticum, Citrobacter sedlakii, Citrobacter werkmanii, Citrobacter youngae, Enterobacter, Hafnia alvei, Klebsiella aerogenes, Morganella morganii, Providencia and Serratia.

only_rsi_columns

a logical to indicate whether only antibiotic columns must be detected that were transformed to class <rsi> (see as.rsi()) on beforehand (defaults to FALSE)

custom_rules

custom rules to apply, created with custom_eucast_rules()

...

column name of an antibiotic, see section Antibiotics below

ab

any (vector of) text that can be coerced to a valid antibiotic code with as.ab()

administration

route of administration, either "im", "iv" or "oral"

Details

Note: This function does not translate MIC values to RSI values. Use as.rsi() for that.
Note: When ampicillin (AMP, J01CA01) is not available but amoxicillin (AMX, J01CA04) is, the latter will be used for all rules where there is a dependency on ampicillin. These drugs are interchangeable when it comes to expression of antimicrobial resistance.

The file containing all EUCAST rules is located here: https://github.com/msberends/AMR/blob/master/data-raw/eucast_rules.tsv. Note: Old taxonomic names are replaced with the current taxonomy where applicable. For example, Ochrobactrum anthropi was renamed to Brucella anthropi in 2020; the original EUCAST rules v3.1 and v3.2 did not yet contain this new taxonomic name. The file used as input for this AMR package contains the taxonomy updated until March 2021.

Custom Rules

Custom rules can be created using custom_eucast_rules(), e.g.:

1
2
3
4
x <- custom_eucast_rules(AMC == "R" & genus == "Klebsiella" ~ aminopenicillins == "R",
                         AMC == "I" & genus == "Klebsiella" ~ aminopenicillins == "I")

eucast_rules(example_isolates, rules = "custom", custom_rules = x)

'Other' Rules

Before further processing, two non-EUCAST rules about drug combinations can be applied to improve the efficacy of the EUCAST rules, and the reliability of your data (analysis). These rules are:

  1. A drug with enzyme inhibitor will be set to S if the same drug without enzyme inhibitor is S

  2. A drug without enzyme inhibitor will be set to R if the same drug with enzyme inhibitor is R

Important examples include amoxicillin and amoxicillin/clavulanic acid, and trimethoprim and trimethoprim/sulfamethoxazole. Needless to say, for these rules to work, both drugs must be available in the data set.

Since these rules are not officially approved by EUCAST, they are not applied at default. To use these rules, include "other" to the rules argument, or use eucast_rules(..., rules = "all"). You can also set the option AMR_eucastrules, i.e. run options(AMR_eucastrules = "all").

Value

The input of x, possibly with edited values of antibiotics. Or, if verbose = TRUE, a data.frame with all original and new values of the affected bug-drug combinations.

Antibiotics

To define antibiotics column names, leave as it is to determine it automatically with guess_ab_col() or input a text (case-insensitive), or use NULL to skip a column (e.g. TIC = NULL to skip ticarcillin). Manually defined but non-existing columns will be skipped with a warning.

The following antibiotics are eligible for the functions eucast_rules() and mdro(). These are shown below in the format 'name (antimicrobial ID, ATC code)', sorted alphabetically:

Amikacin (AMK, J01MA02), amoxicillin (AMX, J01MA04), amoxicillin/clavulanic acid (AMC, J01MA08), ampicillin (AMP, J01MA16), ampicillin/sulbactam (SAM, J01MA15), azidocillin (AZD, J01MA11), azithromycin (AZM, J01MA12), azlocillin (AZL, J01MA07), aztreonam (ATM, J01MA14), bacampicillin (BAM, J01MA06), benzathine benzylpenicillin (BNB, J01MA01), benzathine phenoxymethylpenicillin (BNP, J01MA18), benzylpenicillin (PEN, J01MA03), cadazolid (CDZ, J01MA17), carbenicillin (CRB, J01MA10), carindacillin (CRN, J01MA09), cefacetrile (CAC, J01MA05), cefaclor (CEC, J01MA13), cefadroxil (CFR, J01CA01), cefaloridine (RID, J01CA04), cefamandole (MAN, J01CA12), cefatrizine (CTZ, J01CR05), cefazedone (CZD, J01CA13), cefazolin (CZO, J01AA02), cefdinir (CDR, J01FA10), cefditoren (DIT, J01FA09), cefepime (FEP, J01CR02), cefetamet (CAT, J01AA08), cefixime (CFM, J01FA06), cefmenoxime (CMX, J01CF04), cefmetazole (CMZ, J01CF05), cefodizime (DIZ, J01CR01), cefonicid (CID, J01CE04), cefoperazone (CFP, J01CA09), cefoperazone/sulbactam (CSL, J01DF01), ceforanide (CND, J01CA06), cefotaxime (CTX, J01CE08), cefotetan (CTT, J01CE10), cefotiam (CTF, J01CE01), cefoxitin (FOX, J01CA03), cefpiramide (CPM, J01CA05), cefpirome (CPO, J01CE07), cefpodoxime (CPD, J01CF02), cefprozil (CPR, J01CF01), cefroxadine (CRD, J01CA07), cefsulodin (CFS, J01CA18), ceftaroline (CPT, J01CA11), ceftazidime (CAZ, J01CA14), ceftazidime/avibactam (CZA, J01CF03), ceftazidime/clavulanic acid (CCV, J01CA10), ceftezole (CTL, J01CE06), ceftibuten (CTB, J01CE05), ceftizoxime (CZX, J01CE02), ceftobiprole (BPR, J01CA02), ceftobiprole medocaril (CFM1, J01CA08), ceftolozane/enzyme inhibitor (CEI, J01CE09), ceftriaxone (CRO, J01CE03), cefuroxime (CXM, J01CG01), cephalexin (LEX, J01CA16), cephalothin (CEP, J01CR04), cephapirin (HAP, J01CA15), cephradine (CED, J01CG02), chloramphenicol (CHL, J01CA17), ciprofloxacin (CIP, J01CR03), clarithromycin (CLR, J01DD09), clindamycin (CLI, J01DB10), clometocillin (CLM, J01DC04), cloxacillin (CLO, J01DB05), colistin (COL, J01DB02), cycloserine (CYC, J01DC03), dalbavancin (DAL, J01DB07), daptomycin (DAP, J01DB06), dibekacin (DKB, J01DB04), dicloxacillin (DIC, J01DD15), dirithromycin (DIR, J01DD16), doripenem (DOR, J01DE01), doxycycline (DOX, J01DD10), enoxacin (ENX, J01DD08), epicillin (EPC, J01DD05), ertapenem (ETP, J01DC09), erythromycin (ERY, J01DD09), fleroxacin (FLE, J01DC06), flucloxacillin (FLC, J01DD12), flurithromycin (FLR1, J01DD62), fosfomycin (FOS, J01DC11), fusidic acid (FUS, J01DD01), gatifloxacin (GAT, J01DC05), gemifloxacin (GEM, J01DC07), gentamicin (GEN, J01DC01), grepafloxacin (GRX, J01DD11), hetacillin (HET, J01DE02), imipenem (IPM, J01DD13), isepamicin (ISE, J01DC10), josamycin (JOS, J01DB11), kanamycin (KAN, J01DD03), latamoxef (LTM, J01DI02), levofloxacin (LVX, J01DD02), lincomycin (LIN, J01DD52), linezolid (LNZ, J01DD52), lomefloxacin (LOM, J01DB12), loracarbef (LOR, J01DD14), mecillinam (Amdinocillin) (MEC, J01DD07), meropenem (MEM, J01DI01), meropenem/vaborbactam (MEV, J01DI01), metampicillin (MTM, J01DI54), methicillin (MET, J01DD04), mezlocillin (MEZ, J01DC02), midecamycin (MID, J01DB01), minocycline (MNO, J01DB03), miocamycin (MCM, J01DB08), moxifloxacin (MFX, J01DB09), nalidixic acid (NAL, J01DD06), neomycin (NEO, J01DC08), netilmicin (NET, J01DH04), nitrofurantoin (NIT, J01DH03), norfloxacin (NOR, J01DH51), novobiocin (NOV, J01DH02), ofloxacin (OFX, J01DH52), oleandomycin (OLE, J01XA02), oritavancin (ORI, J01XA01), oxacillin (OXA, J01XC01), pazufloxacin (PAZ, J01FA13), pefloxacin (PEF, J01FA01), penamecillin (PNM, J01FA14), phenethicillin (PHE, J01FA07), phenoxymethylpenicillin (PHN, J01FA03), piperacillin (PIP, J01FA11), piperacillin/tazobactam (TZP, J01FA05), pivampicillin (PVM, J01FA12), pivmecillinam (PME, J01FA02), polymyxin B (PLB, J01FA15), pristinamycin (PRI, J01FA08), procaine benzylpenicillin (PRB, J01FF02), propicillin (PRP, J01FG01), prulifloxacin (PRU, J01FG02), quinupristin/dalfopristin (QDA, J04AB02), ribostamycin (RST, J01XX09), rifampicin (RIF, J01XX08), rokitamycin (ROK, J01AA07), roxithromycin (RXT, J01XB01), rufloxacin (RFL, J01XB02), sisomicin (SIS, J01XE01), sparfloxacin (SPX, J01AA12), spiramycin (SPI, J01EA01), streptoduocin (STR, J01XX01), streptomycin (STR1, J01BA01), sulbactam (SUL, J01GB06), sulbenicillin (SBC, J01GB09), sulfadiazine (SDI, J01GB03), sulfadiazine/trimethoprim (SLT1, J01GB11), sulfadimethoxine (SUD, J01GB04), sulfadimidine (SDM, J01GB05), sulfadimidine/trimethoprim (SLT2, J01GB07), sulfafurazole (SLF, J01GB10), sulfaisodimidine (SLF1, J01GB08), sulfalene (SLF2, J01GA02), sulfamazone (SZO, J01GA01), sulfamerazine (SLF3, J01GB01), sulfamerazine/trimethoprim (SLT3, J01EE01), sulfamethizole (SLF4, J01MB02), sulfamethoxazole (SMX, QJ01XX95), sulfamethoxypyridazine (SLF5, J01FF01), sulfametomidine (SLF6, J01XA04), sulfametoxydiazine (SLF7, J01XA05), sulfametrole/trimethoprim (SLT4, J01XA03), sulfamoxole (SLF8, J04AB01), sulfamoxole/trimethoprim (SLT5, J01XX11), sulfanilamide (SLF9, J01EC02), sulfaperin (SLF10, J01ED01), sulfaphenazole (SLF11, J01EB03), sulfapyridine (SLF12, J01EB05), sulfathiazole (SUT, J01EB01), sulfathiourea (SLF13, J01ED02), sultamicillin (SLT6, J01ED09), talampicillin (TAL, J01ED07), tazobactam (TAZ, J01EB02), tedizolid (TZD, J01EC01), teicoplanin (TEC, J01ED05), telavancin (TLV, J01ED03), telithromycin (TLT, J01ED04), temafloxacin (TMX, J01EC03), temocillin (TEM, J01EB06), tetracycline (TCY, J01ED06), ticarcillin (TIC, J01ED08), ticarcillin/clavulanic acid (TCC, J01EB04), tigecycline (TGC, J01EB07), tobramycin (TOB, J01EB08), trimethoprim (TMP, J01EE02), trimethoprim/sulfamethoxazole (SXT, J01EE05), troleandomycin (TRL, J01EE07), trovafloxacin (TVA, J01EE03), vancomycin (VAN, J01EE04)

Stable Lifecycle


The lifecycle of this function is stable. In a stable function, major changes are unlikely. This means that the unlying code will generally evolve by adding new arguments; removing arguments or changing the meaning of existing arguments will be avoided.

If the unlying code needs breaking changes, they will occur gradually. For example, a argument will be deprecated and first continue to work, but will emit an message informing you of the change. Next, typically after at least one newly released version on CRAN, the message will be transformed to an error.

Reference Data Publicly Available

All reference data sets (about microorganisms, antibiotics, R/SI interpretation, EUCAST rules, etc.) in this AMR package are publicly and freely available. We continually export our data sets to formats for use in R, SPSS, SAS, Stata and Excel. We also supply flat files that are machine-readable and suitable for input in any software program, such as laboratory information systems. Please find all download links on our website, which is automatically updated with every code change.

Read more on Our Website!

On our website https://msberends.github.io/AMR/ you can find a comprehensive tutorial about how to conduct AMR data analysis, the complete documentation of all functions and an example analysis using WHONET data.

Source

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
a <- data.frame(mo = c("Staphylococcus aureus",
                       "Enterococcus faecalis",
                       "Escherichia coli",
                       "Klebsiella pneumoniae",
                       "Pseudomonas aeruginosa"),
                VAN = "-",       # Vancomycin
                AMX = "-",       # Amoxicillin
                COL = "-",       # Colistin
                CAZ = "-",       # Ceftazidime
                CXM = "-",       # Cefuroxime
                PEN = "S",       # Benzylpenicillin
                FOX = "S",       # Cefoxitin
                stringsAsFactors = FALSE)

a
#                       mo  VAN  AMX  COL  CAZ  CXM  PEN  FOX
# 1  Staphylococcus aureus    -    -    -    -    -    S    S
# 2  Enterococcus faecalis    -    -    -    -    -    S    S
# 3       Escherichia coli    -    -    -    -    -    S    S
# 4  Klebsiella pneumoniae    -    -    -    -    -    S    S
# 5 Pseudomonas aeruginosa    -    -    -    -    -    S    S


# apply EUCAST rules: some results wil be changed
b <- eucast_rules(a)

b
#                       mo  VAN  AMX  COL  CAZ  CXM  PEN  FOX
# 1  Staphylococcus aureus    -    S    R    R    S    S    S
# 2  Enterococcus faecalis    -    -    R    R    R    S    R
# 3       Escherichia coli    R    -    -    -    -    R    S
# 4  Klebsiella pneumoniae    R    R    -    -    -    R    S
# 5 Pseudomonas aeruginosa    R    R    -    -    R    R    R


# do not apply EUCAST rules, but rather get a data.frame
# containing all details about the transformations:
c <- eucast_rules(a, verbose = TRUE)


eucast_dosage(c("tobra", "genta", "cipro"), "iv")

AMR documentation built on June 3, 2021, 5:09 p.m.