-| 2026-03-06 |
+2026-03-07 |
efgh |
Escherichia coli |
R |
@@ -407,7 +407,7 @@ the methods on the first_isolate
#> ℹ Using column 'patient_id' as input for `col_patient_id`.
#> ℹ Basing inclusion on all antimicrobial results, using a points threshold
#> of 2
-#> => Found 2,730 'phenotype-based' first isolates (91.0% of total where a
+#> => Found 2,724 'phenotype-based' first isolates (90.8% of total where a
#> microbial ID was available)
So only 91% is suitable for resistance analysis! We can now filter on
it with the filter() function, also from the
@@ -419,11 +419,11 @@ it with the
our_data_1st <- our_data %>%
filter_first_isolate()
-So we end up with 2 730 isolates for analysis. Now our data looks
+
So we end up with 2 724 isolates for analysis. Now our data looks
like:
our_data_1st
-#> # A tibble: 2,730 × 9
+#> # A tibble: 2,724 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#> <chr> <chr> <date> <mo> <sir> <sir> <sir> <sir> <lgl>
#> 1 J3 A 2012-11-21 B_ESCHR_COLI R I S S TRUE
@@ -436,7 +436,7 @@ like:
#> 8 J3 A 2019-06-19 B_ESCHR_COLI S S S S TRUE
#> 9 G6 A 2015-04-27 B_STPHY_AURS S S S S TRUE
#> 10 P4 A 2011-06-21 B_ESCHR_COLI S S S S TRUE
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
Time for the analysis.
@@ -449,29 +449,29 @@ impression, as it comes with support for the new mo and
summary(our_data_1st)
#> patient_id hospital date
-#> Length:2730 Length:2730 Min. :2011-01-01
-#> Class :character Class :character 1st Qu.:2013-04-06
-#> Mode :character Mode :character Median :2015-06-04
+#> Length:2724 Length:2724 Min. :2011-01-01
+#> Class :character Class :character 1st Qu.:2013-04-07
+#> Mode :character Mode :character Median :2015-06-03
#> Mean :2015-06-09
-#> 3rd Qu.:2017-08-14
+#> 3rd Qu.:2017-08-11
#> Max. :2019-12-27
#> bacteria AMX AMC
#> Class :mo Class:sir Class:sir
-#> <NA> :0 %S :40.1% (n=1071) %S :51.1% (n=1354)
+#> <NA> :0 %S :41.6% (n=1133) %S :52.6% (n=1432)
#> Unique:4 %SDD : 0.0% (n=0) %SDD : 0.0% (n=0)
-#> #1 :B_ESCHR_COLI %I :17.0% (n=453) %I :12.7% (n=335)
-#> #2 :B_STPHY_AURS %R :42.9% (n=1147) %R :36.2% (n=959)
+#> #1 :B_ESCHR_COLI %I :16.4% (n=446) %I :12.2% (n=333)
+#> #2 :B_STPHY_AURS %R :42.0% (n=1145) %R :35.2% (n=959)
#> #3 :B_STRPT_PNMN %NI : 0.0% (n=0) %NI : 0.0% (n=0)
#> CIP GEN first
#> Class:sir Class:sir Mode:logical
-#> %S :52.2% (n=1426) %S :60.7% (n=1656) TRUE:2730
+#> %S :52.5% (n=1431) %S :61.0% (n=1661) TRUE:2724
#> %SDD : 0.0% (n=0) %SDD : 0.0% (n=0)
-#> %I : 6.5% (n=178) %I : 3.0% (n=83)
-#> %R :41.2% (n=1126) %R :36.3% (n=991)
+#> %I : 6.5% (n=176) %I : 3.0% (n=82)
+#> %R :41.0% (n=1117) %R :36.0% (n=981)
#> %NI : 0.0% (n=0) %NI : 0.0% (n=0)
glimpse(our_data_1st)
-#> Rows: 2,730
+#> Rows: 2,724
#> Columns: 9
#> $ patient_id <chr> "J3", "R7", "P3", "P10", "B7", "W3", "M3", "J3", "G6", "P4"…
#> $ hospital <chr> "A", "A", "A", "A", "A", "A", "A", "A", "A", "A", "A", "A",…
@@ -486,7 +486,7 @@ impression, as it comes with support for the new mo and
# number of unique values per column:
sapply(our_data_1st, n_distinct)
#> patient_id hospital date bacteria AMX AMC CIP
-#> 260 3 1854 4 4 4 3
+#> 260 3 1854 4 3 3 3
#> GEN first
#> 3 1
@@ -511,9 +511,9 @@ microorganisms:
#> # A tibble: 4 × 2
#> `mo_name(bacteria)` n
#> <chr> <int>
-#> 1 Escherichia coli 1326
-#> 2 Staphylococcus aureus 684
-#> 3 Streptococcus pneumoniae 401
+#> 1 Escherichia coli 1321
+#> 2 Staphylococcus aureus 682
+#> 3 Streptococcus pneumoniae 402
#> 4 Klebsiella pneumoniae 319
@@ -526,7 +526,7 @@ in:
our_data_1st %>%
select(date, aminoglycosides())
#> ℹ For `aminoglycosides()` using column 'GEN' (gentamicin)
-#> # A tibble: 2,730 × 2
+#> # A tibble: 2,724 × 2
#> date GEN
#> <date> <sir>
#> 1 2012-11-21 S
@@ -539,13 +539,13 @@ in:
#> 8 2019-06-19 S
#> 9 2015-04-27 S
#> 10 2011-06-21 S
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
our_data_1st %>%
select(bacteria, betalactams())
#> ℹ For `betalactams()` using columns 'AMX' (amoxicillin) and 'AMC'
#> (amoxicillin/clavulanic acid)
-#> # A tibble: 2,730 × 3
+#> # A tibble: 2,724 × 3
#> bacteria AMX AMC
#> <mo> <sir> <sir>
#> 1 B_ESCHR_COLI R I
@@ -558,11 +558,11 @@ in:
#> 8 B_ESCHR_COLI S S
#> 9 B_STPHY_AURS S S
#> 10 B_ESCHR_COLI S S
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
our_data_1st %>%
select(bacteria, where(is.sir))
-#> # A tibble: 2,730 × 5
+#> # A tibble: 2,724 × 5
#> bacteria AMX AMC CIP GEN
#> <mo> <sir> <sir> <sir> <sir>
#> 1 B_ESCHR_COLI R I S S
@@ -575,13 +575,13 @@ in:
#> 8 B_ESCHR_COLI S S S S
#> 9 B_STPHY_AURS S S S S
#> 10 B_ESCHR_COLI S S S S
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
# filtering using AB selectors is also possible:
our_data_1st %>%
filter(any(aminoglycosides() == "R"))
#> ℹ For `aminoglycosides()` using column 'GEN' (gentamicin)
-#> # A tibble: 991 × 9
+#> # A tibble: 981 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#> <chr> <chr> <date> <mo> <sir> <sir> <sir> <sir> <lgl>
#> 1 J5 A 2017-12-25 B_STRPT_PNMN R S S R TRUE
@@ -594,13 +594,13 @@ in:
#> 8 P5 A 2019-03-09 B_STPHY_AURS S S S R TRUE
#> 9 Q8 A 2019-08-10 B_STPHY_AURS S S S R TRUE
#> 10 K5 A 2013-03-15 B_STRPT_PNMN S S S R TRUE
-#> # ℹ 981 more rows
+#> # ℹ 971 more rows
our_data_1st %>%
filter(all(betalactams() == "R"))
#> ℹ For `betalactams()` using columns 'AMX' (amoxicillin) and 'AMC'
#> (amoxicillin/clavulanic acid)
-#> # A tibble: 461 × 9
+#> # A tibble: 462 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#> <chr> <chr> <date> <mo> <sir> <sir> <sir> <sir> <lgl>
#> 1 M7 A 2013-07-22 B_STRPT_PNMN R R S S TRUE
@@ -613,13 +613,13 @@ in:
#> 8 Q2 A 2019-09-22 B_ESCHR_COLI R R S S TRUE
#> 9 X7 A 2011-03-20 B_ESCHR_COLI R R S R TRUE
#> 10 V1 A 2018-08-07 B_STPHY_AURS R R S S TRUE
-#> # ℹ 451 more rows
+#> # ℹ 452 more rows
# even works in base R (since R 3.0):
our_data_1st[all(betalactams() == "R"), ]
#> ℹ For `betalactams()` using columns 'AMX' (amoxicillin) and 'AMC'
#> (amoxicillin/clavulanic acid)
-#> # A tibble: 461 × 9
+#> # A tibble: 462 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#> <chr> <chr> <date> <mo> <sir> <sir> <sir> <sir> <lgl>
#> 1 M7 A 2013-07-22 B_STRPT_PNMN R R S S TRUE
@@ -632,7 +632,7 @@ in:
#> 8 Q2 A 2019-09-22 B_ESCHR_COLI R R S S TRUE
#> 9 X7 A 2011-03-20 B_ESCHR_COLI R R S R TRUE
#> 10 V1 A 2018-08-07 B_STPHY_AURS R R S S TRUE
-#> # ℹ 451 more rows
+#> # ℹ 452 more rows
Generate antibiograms
@@ -1289,7 +1289,7 @@ own:
#> category susceptible. Set the `guideline` argument or the `AMR_guideline`
#> option to either "CLSI" or "EUCAST", see `?AMR-options`.
#> ℹ This message will be shown once per session.
-#> [1] 0.4294272
+#> [1] 0.4203377
Or can be used in conjunction with group_by() and
summarise(), both from the dplyr package:
@@ -1299,8 +1299,8 @@ own:
#> # A tibble: 3 × 2
#> hospital amoxicillin
#> <chr> <dbl>
-#> 1 A 0.341
-#> 2 B 0.586
+#> 1 A 0.340
+#> 2 B 0.551
#> 3 C 0.370
diff --git a/articles/AMR.md b/articles/AMR.md
index ea4edd69a..8d9042a00 100644
--- a/articles/AMR.md
+++ b/articles/AMR.md
@@ -3,7 +3,7 @@
**Note:** values on this page will change with every website update
since they are based on randomly created values and the page was written
in [R Markdown](https://rmarkdown.rstudio.com/). However, the
-methodology remains unchanged. This page was generated on 06 March 2026.
+methodology remains unchanged. This page was generated on 07 March 2026.
## Introduction
@@ -51,9 +51,9 @@ structure of your data generally look like this:
| date | patient_id | mo | AMX | CIP |
|:----------:|:----------:|:----------------:|:---:|:---:|
-| 2026-03-06 | abcd | Escherichia coli | S | S |
-| 2026-03-06 | abcd | Escherichia coli | S | R |
-| 2026-03-06 | efgh | Escherichia coli | R | S |
+| 2026-03-07 | abcd | Escherichia coli | S | S |
+| 2026-03-07 | abcd | Escherichia coli | S | R |
+| 2026-03-07 | efgh | Escherichia coli | R | S |
### Needed R packages
@@ -323,7 +323,7 @@ our_data <- our_data %>%
#> ℹ Using column 'patient_id' as input for `col_patient_id`.
#> ℹ Basing inclusion on all antimicrobial results, using a points threshold
#> of 2
-#> => Found 2,730 'phenotype-based' first isolates (91.0% of total where a
+#> => Found 2,724 'phenotype-based' first isolates (90.8% of total where a
#> microbial ID was available)
```
@@ -343,11 +343,11 @@ our_data_1st <- our_data %>%
filter_first_isolate()
```
-So we end up with 2 730 isolates for analysis. Now our data looks like:
+So we end up with 2 724 isolates for analysis. Now our data looks like:
``` r
our_data_1st
-#> # A tibble: 2,730 × 9
+#> # A tibble: 2,724 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#>
#> 1 J3 A 2012-11-21 B_ESCHR_COLI R I S S TRUE
@@ -360,7 +360,7 @@ our_data_1st
#> 8 J3 A 2019-06-19 B_ESCHR_COLI S S S S TRUE
#> 9 G6 A 2015-04-27 B_STPHY_AURS S S S S TRUE
#> 10 P4 A 2011-06-21 B_ESCHR_COLI S S S S TRUE
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
```
Time for the analysis.
@@ -374,29 +374,29 @@ and `sir` classes that we now have in our data set:
``` r
summary(our_data_1st)
#> patient_id hospital date
-#> Length:2730 Length:2730 Min. :2011-01-01
-#> Class :character Class :character 1st Qu.:2013-04-06
-#> Mode :character Mode :character Median :2015-06-04
+#> Length:2724 Length:2724 Min. :2011-01-01
+#> Class :character Class :character 1st Qu.:2013-04-07
+#> Mode :character Mode :character Median :2015-06-03
#> Mean :2015-06-09
-#> 3rd Qu.:2017-08-14
+#> 3rd Qu.:2017-08-11
#> Max. :2019-12-27
#> bacteria AMX AMC
#> Class :mo Class:sir Class:sir
-#> :0 %S :40.1% (n=1071) %S :51.1% (n=1354)
+#> :0 %S :41.6% (n=1133) %S :52.6% (n=1432)
#> Unique:4 %SDD : 0.0% (n=0) %SDD : 0.0% (n=0)
-#> #1 :B_ESCHR_COLI %I :17.0% (n=453) %I :12.7% (n=335)
-#> #2 :B_STPHY_AURS %R :42.9% (n=1147) %R :36.2% (n=959)
+#> #1 :B_ESCHR_COLI %I :16.4% (n=446) %I :12.2% (n=333)
+#> #2 :B_STPHY_AURS %R :42.0% (n=1145) %R :35.2% (n=959)
#> #3 :B_STRPT_PNMN %NI : 0.0% (n=0) %NI : 0.0% (n=0)
#> CIP GEN first
#> Class:sir Class:sir Mode:logical
-#> %S :52.2% (n=1426) %S :60.7% (n=1656) TRUE:2730
+#> %S :52.5% (n=1431) %S :61.0% (n=1661) TRUE:2724
#> %SDD : 0.0% (n=0) %SDD : 0.0% (n=0)
-#> %I : 6.5% (n=178) %I : 3.0% (n=83)
-#> %R :41.2% (n=1126) %R :36.3% (n=991)
+#> %I : 6.5% (n=176) %I : 3.0% (n=82)
+#> %R :41.0% (n=1117) %R :36.0% (n=981)
#> %NI : 0.0% (n=0) %NI : 0.0% (n=0)
glimpse(our_data_1st)
-#> Rows: 2,730
+#> Rows: 2,724
#> Columns: 9
#> $ patient_id "J3", "R7", "P3", "P10", "B7", "W3", "M3", "J3", "G6", "P4"…
#> $ hospital "A", "A", "A", "A", "A", "A", "A", "A", "A", "A", "A", "A",…
@@ -411,7 +411,7 @@ glimpse(our_data_1st)
# number of unique values per column:
sapply(our_data_1st, n_distinct)
#> patient_id hospital date bacteria AMX AMC CIP
-#> 260 3 1854 4 4 4 3
+#> 260 3 1854 4 3 3 3
#> GEN first
#> 3 1
```
@@ -438,9 +438,9 @@ our_data_1st %>%
#> # A tibble: 4 × 2
#> `mo_name(bacteria)` n
#>
-#> 1 Escherichia coli 1326
-#> 2 Staphylococcus aureus 684
-#> 3 Streptococcus pneumoniae 401
+#> 1 Escherichia coli 1321
+#> 2 Staphylococcus aureus 682
+#> 3 Streptococcus pneumoniae 402
#> 4 Klebsiella pneumoniae 319
```
@@ -454,7 +454,7 @@ in:
our_data_1st %>%
select(date, aminoglycosides())
#> ℹ For `aminoglycosides()` using column 'GEN' (gentamicin)
-#> # A tibble: 2,730 × 2
+#> # A tibble: 2,724 × 2
#> date GEN
#>
#> 1 2012-11-21 S
@@ -467,13 +467,13 @@ our_data_1st %>%
#> 8 2019-06-19 S
#> 9 2015-04-27 S
#> 10 2011-06-21 S
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
our_data_1st %>%
select(bacteria, betalactams())
#> ℹ For `betalactams()` using columns 'AMX' (amoxicillin) and 'AMC'
#> (amoxicillin/clavulanic acid)
-#> # A tibble: 2,730 × 3
+#> # A tibble: 2,724 × 3
#> bacteria AMX AMC
#>
#> 1 B_ESCHR_COLI R I
@@ -486,11 +486,11 @@ our_data_1st %>%
#> 8 B_ESCHR_COLI S S
#> 9 B_STPHY_AURS S S
#> 10 B_ESCHR_COLI S S
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
our_data_1st %>%
select(bacteria, where(is.sir))
-#> # A tibble: 2,730 × 5
+#> # A tibble: 2,724 × 5
#> bacteria AMX AMC CIP GEN
#>
#> 1 B_ESCHR_COLI R I S S
@@ -503,13 +503,13 @@ our_data_1st %>%
#> 8 B_ESCHR_COLI S S S S
#> 9 B_STPHY_AURS S S S S
#> 10 B_ESCHR_COLI S S S S
-#> # ℹ 2,720 more rows
+#> # ℹ 2,714 more rows
# filtering using AB selectors is also possible:
our_data_1st %>%
filter(any(aminoglycosides() == "R"))
#> ℹ For `aminoglycosides()` using column 'GEN' (gentamicin)
-#> # A tibble: 991 × 9
+#> # A tibble: 981 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#>
#> 1 J5 A 2017-12-25 B_STRPT_PNMN R S S R TRUE
@@ -522,13 +522,13 @@ our_data_1st %>%
#> 8 P5 A 2019-03-09 B_STPHY_AURS S S S R TRUE
#> 9 Q8 A 2019-08-10 B_STPHY_AURS S S S R TRUE
#> 10 K5 A 2013-03-15 B_STRPT_PNMN S S S R TRUE
-#> # ℹ 981 more rows
+#> # ℹ 971 more rows
our_data_1st %>%
filter(all(betalactams() == "R"))
#> ℹ For `betalactams()` using columns 'AMX' (amoxicillin) and 'AMC'
#> (amoxicillin/clavulanic acid)
-#> # A tibble: 461 × 9
+#> # A tibble: 462 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#>
#> 1 M7 A 2013-07-22 B_STRPT_PNMN R R S S TRUE
@@ -541,13 +541,13 @@ our_data_1st %>%
#> 8 Q2 A 2019-09-22 B_ESCHR_COLI R R S S TRUE
#> 9 X7 A 2011-03-20 B_ESCHR_COLI R R S R TRUE
#> 10 V1 A 2018-08-07 B_STPHY_AURS R R S S TRUE
-#> # ℹ 451 more rows
+#> # ℹ 452 more rows
# even works in base R (since R 3.0):
our_data_1st[all(betalactams() == "R"), ]
#> ℹ For `betalactams()` using columns 'AMX' (amoxicillin) and 'AMC'
#> (amoxicillin/clavulanic acid)
-#> # A tibble: 461 × 9
+#> # A tibble: 462 × 9
#> patient_id hospital date bacteria AMX AMC CIP GEN first
#>
#> 1 M7 A 2013-07-22 B_STRPT_PNMN R R S S TRUE
@@ -560,7 +560,7 @@ our_data_1st[all(betalactams() == "R"), ]
#> 8 Q2 A 2019-09-22 B_ESCHR_COLI R R S S TRUE
#> 9 X7 A 2011-03-20 B_ESCHR_COLI R R S R TRUE
#> 10 V1 A 2018-08-07 B_STPHY_AURS R R S S TRUE
-#> # ℹ 451 more rows
+#> # ℹ 452 more rows
```
### Generate antibiograms
@@ -848,7 +848,7 @@ our_data_1st %>% resistance(AMX)
#> category susceptible. Set the `guideline` argument or the `AMR_guideline`
#> option to either "CLSI" or "EUCAST", see `?AMR-options`.
#> ℹ This message will be shown once per session.
-#> [1] 0.4294272
+#> [1] 0.4203377
```
Or can be used in conjunction with
@@ -863,8 +863,8 @@ our_data_1st %>%
#> # A tibble: 3 × 2
#> hospital amoxicillin
#>
-#> 1 A 0.341
-#> 2 B 0.586
+#> 1 A 0.340
+#> 2 B 0.551
#> 3 C 0.370
```
diff --git a/articles/AMR_for_Python.html b/articles/AMR_for_Python.html
index 2a882b87d..9ff3319b0 100644
--- a/articles/AMR_for_Python.html
+++ b/articles/AMR_for_Python.html
@@ -30,7 +30,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
#> Groups (n=4, named as 'order'):
diff --git a/articles/PCA.md b/articles/PCA.md
index bf7e4a5f2..9e63716e5 100644
--- a/articles/PCA.md
+++ b/articles/PCA.md
@@ -117,7 +117,7 @@ summary(pca_result)
#> [1] "Caryophanales" "Enterobacterales" "Lactobacillales" "Pseudomonadales"
#> Importance of components:
#> PC1 PC2 PC3 PC4 PC5 PC6 PC7
-#> Standard deviation 2.1539 1.6807 0.6138 0.33879 0.20808 0.03140 9.577e-17
+#> Standard deviation 2.1539 1.6807 0.6138 0.33879 0.20808 0.03140 1.232e-16
#> Proportion of Variance 0.5799 0.3531 0.0471 0.01435 0.00541 0.00012 0.000e+00
#> Cumulative Proportion 0.5799 0.9330 0.9801 0.99446 0.99988 1.00000 1.000e+00
```
diff --git a/articles/WHONET.html b/articles/WHONET.html
index cc46fb5a6..1fcbee81d 100644
--- a/articles/WHONET.html
+++ b/articles/WHONET.html
@@ -30,7 +30,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/articles/WISCA.html b/articles/WISCA.html
index 359af3146..f78e51742 100644
--- a/articles/WISCA.html
+++ b/articles/WISCA.html
@@ -30,7 +30,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/articles/datasets.html b/articles/datasets.html
index b04fc123b..e30cc3b9f 100644
--- a/articles/datasets.html
+++ b/articles/datasets.html
@@ -30,7 +30,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
@@ -80,7 +80,7 @@
-
AMR 3.0.1.9026
+
AMR 3.0.1.9030
-
New
+
New
- Integration with the tidymodels framework to allow seamless use of SIR, MIC and disk data in modelling pipelines via
recipes
-
step_mic_log2() to transform <mic> columns with log2, and step_sir_numeric() to convert <sir> columns to numeric
@@ -84,17 +84,22 @@
- Two new
NA objects, NA_ab_ and NA_mo_, analogous to base R’s NA_character_ and NA_integer_, for use in pipelines that require typed missing values
-
Fixes
-
- Fixed a bug in
as.ab() where certain AB codes containing “PH” or “TH” (such as ETH, MTH, PHE, PHN, STH, THA, THI1) would incorrectly return NA when combined in a vector with any untranslatable value (#245)
+Fixes
+-
+
mdro(): when a base beta-lactam drug column is missing but a corresponding drug+inhibitor combination is present in the data and resistant (e.g., piperacillin/tazobactam = R while piperacillin is absent), the base drug is now correctly inferred as resistant. This ensures MDRO classification is not missed due to test-ordering differences in the laboratory. The reverse direction is also valid: susceptibility in a combination does not imply susceptibility in the base drug (the inhibitor may be responsible), so only resistance is propagated. Closes #209
+- Fixed a bug in
as.sir() where values that were purely numeric (e.g., "1") and matched the broad SIR-matching regex would be incorrectly stripped of all content by the Unicode letter filter
+- Fixed a bug in
as.mic() where MIC values in scientific notation (e.g., "1e-3") were incorrectly handled because the letter e was removed along with other Unicode letters; scientific notation e is now preserved
+- Fixed a bug in
as.ab() where certain AB codes containing “PH” or “TH” (such as ETH, MTH, PHE, PHN, STH, THA, THI1) would incorrectly return NA when combined in a vector with any untranslatable value (#245)
- Fixed a bug in
antibiogram() for when no antimicrobials are set
- Fixed a bug in
as.sir() where for numeric input the arguments S, I, and R would not be considered (#244)
- Fixed some foreign translations of antimicrobial drugs
- Fixed a bug for printing column names to the console when using
mutate_at(vars(...), as.mic) (#249)
- Fixed a bug to disregard
NI for susceptibility proportion functions
- Fixed Italian translation of CoNS to Stafilococco coagulasi-negativo and CoPS to Stafilococco coagulasi-positivo (#256)
+- Fixed SIR and MIC coercion of combined values, e.g.
as.sir("<= 0.002; S") or as.mic("S; 0.002") (#252)
-
Updates
+
Updates
-
susceptibility() and resistance() gained the argument guideline, which defaults to EUCAST, for interpreting the ‘I’ category correctly.
-
diff --git a/news/index.md b/news/index.md
index 7aa46f76a..b747c8dfb 100644
--- a/news/index.md
+++ b/news/index.md
@@ -1,6 +1,6 @@
# Changelog
-## AMR 3.0.1.9026
+## AMR 3.0.1.9030
#### New
@@ -45,6 +45,24 @@
#### Fixes
+- [`mdro()`](https://amr-for-r.org/reference/mdro.md): when a base
+ beta-lactam drug column is missing but a corresponding drug+inhibitor
+ combination is present in the data and resistant (e.g.,
+ piperacillin/tazobactam = R while piperacillin is absent), the base
+ drug is now correctly inferred as resistant. This ensures MDRO
+ classification is not missed due to test-ordering differences in the
+ laboratory. The reverse direction is also valid: susceptibility in a
+ combination does not imply susceptibility in the base drug (the
+ inhibitor may be responsible), so only resistance is propagated.
+ Closes [\#209](https://github.com/msberends/AMR/issues/209)
+- Fixed a bug in [`as.sir()`](https://amr-for-r.org/reference/as.sir.md)
+ where values that were purely numeric (e.g., `"1"`) and matched the
+ broad SIR-matching regex would be incorrectly stripped of all content
+ by the Unicode letter filter
+- Fixed a bug in [`as.mic()`](https://amr-for-r.org/reference/as.mic.md)
+ where MIC values in scientific notation (e.g., `"1e-3"`) were
+ incorrectly handled because the letter `e` was removed along with
+ other Unicode letters; scientific notation `e` is now preserved
- Fixed a bug in [`as.ab()`](https://amr-for-r.org/reference/as.ab.md)
where certain AB codes containing “PH” or “TH” (such as `ETH`, `MTH`,
`PHE`, `PHN`, `STH`, `THA`, `THI1`) would incorrectly return `NA` when
@@ -64,6 +82,9 @@
- Fixed Italian translation of CoNS to Stafilococco coagulasi-negativo
and CoPS to Stafilococco coagulasi-positivo
([\#256](https://github.com/msberends/AMR/issues/256))
+- Fixed SIR and MIC coercion of combined values,
+ e.g. `as.sir("<= 0.002; S")` or `as.mic("S; 0.002")`
+ ([\#252](https://github.com/msberends/AMR/issues/252))
#### Updates
diff --git a/pkgdown.yml b/pkgdown.yml
index a67250689..760ba82b3 100644
--- a/pkgdown.yml
+++ b/pkgdown.yml
@@ -10,7 +10,7 @@ articles:
PCA: PCA.html
WHONET: WHONET.html
WISCA: WISCA.html
-last_built: 2026-03-06T11:51Z
+last_built: 2026-03-07T17:10Z
urls:
reference: https://amr-for-r.org/reference
article: https://amr-for-r.org/articles
diff --git a/reference/AMR-deprecated.html b/reference/AMR-deprecated.html
index 7fa7a3146..3db60d5a4 100644
--- a/reference/AMR-deprecated.html
+++ b/reference/AMR-deprecated.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/AMR-options.html b/reference/AMR-options.html
index 1832a4c7c..fde1f8418 100644
--- a/reference/AMR-options.html
+++ b/reference/AMR-options.html
@@ -9,7 +9,7 @@ options(AMR_guideline = "CLSI")'>AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/AMR.html b/reference/AMR.html
index e0da547fe..9cb2f1fa1 100644
--- a/reference/AMR.html
+++ b/reference/AMR.html
@@ -21,7 +21,7 @@ The AMR package is available in English, Arabic, Bengali, Chinese, Czech, Danish
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/WHOCC.html b/reference/WHOCC.html
index 5b7ab225b..711325c37 100644
--- a/reference/WHOCC.html
+++ b/reference/WHOCC.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/WHONET.html b/reference/WHONET.html
index c43c89a64..4c66fd3ee 100644
--- a/reference/WHONET.html
+++ b/reference/WHONET.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/ab_from_text.html b/reference/ab_from_text.html
index 8ce1e6666..49ffb398a 100644
--- a/reference/ab_from_text.html
+++ b/reference/ab_from_text.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/ab_property.html b/reference/ab_property.html
index cdf26a9f8..41cc52116 100644
--- a/reference/ab_property.html
+++ b/reference/ab_property.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
@@ -108,7 +108,7 @@
- all_groups
-A logical to indicate whether all antimicrobial groups must be return as a vector for each input value. For example, an antibiotic in the "aminopenicillins" group, is also in the "penicillins" and "beta-lactams" groups. Setting all_groups = TRUE would return all three for such an antibiotic, while all_groups = FALSE (default) only returns the most distinctive group name.
+A logical to indicate whether all antimicrobial groups must be return as a vector for each input value. For example, an antibiotic in the "aminopenicillins" group, is also in the "penicillins" and "beta-lactams" groups. Setting all_groups = TRUE would return all three for such an antibiotic, while all_groups = FALSE (default) only returns the most specific group name.
- only_first
@@ -231,6 +231,8 @@
#> [93] "zimox"
ab_group("AMX")
#> [1] "Aminopenicillins"
+ab_group("AMX", all_groups = TRUE) # most specific to most general
+#> [1] "Aminopenicillins" "Penicillins" "Beta-lactams"
ab_atc_group1("AMX")
#> [1] "Beta-lactam antibacterials, penicillins"
ab_atc_group2("AMX")
diff --git a/reference/ab_property.md b/reference/ab_property.md
index 408bef47d..23d3b871d 100644
--- a/reference/ab_property.md
+++ b/reference/ab_property.md
@@ -79,7 +79,7 @@ set_ab_names(data, ..., property = "name", language = get_AMR_locale(),
value. For example, an antibiotic in the "aminopenicillins" group, is
also in the "penicillins" and "beta-lactams" groups. Setting
`all_groups = TRUE` would return all three for such an antibiotic,
- while `all_groups = FALSE` (default) only returns the most distinctive
+ while `all_groups = FALSE` (default) only returns the most specific
group name.
- only_first:
@@ -239,6 +239,8 @@ ab_tradenames("AMX")
#> [93] "zimox"
ab_group("AMX")
#> [1] "Aminopenicillins"
+ab_group("AMX", all_groups = TRUE) # most specific to most general
+#> [1] "Aminopenicillins" "Penicillins" "Beta-lactams"
ab_atc_group1("AMX")
#> [1] "Beta-lactam antibacterials, penicillins"
ab_atc_group2("AMX")
diff --git a/reference/add_custom_antimicrobials.html b/reference/add_custom_antimicrobials.html
index a134ac5f0..97f54207f 100644
--- a/reference/add_custom_antimicrobials.html
+++ b/reference/add_custom_antimicrobials.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/add_custom_microorganisms.html b/reference/add_custom_microorganisms.html
index 83657a8fa..46eee6051 100644
--- a/reference/add_custom_microorganisms.html
+++ b/reference/add_custom_microorganisms.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
diff --git a/reference/age.html b/reference/age.html
index e2a132711..6aa5bbf97 100644
--- a/reference/age.html
+++ b/reference/age.html
@@ -7,7 +7,7 @@
AMR (for R)
- 3.0.1.9026
+ 3.0.1.9030
@@ -112,16 +112,16 @@
df
#> birth_date age age_exact age_at_y2k
-#> 1 1980-02-27 46 46.01918 19
-#> 2 1953-07-26 72 72.61096 46
-#> 3 1949-09-02 76 76.50685 50
-#> 4 1986-08-03 39 39.58904 13
-#> 5 1932-11-19 93 93.29315 67
-#> 6 1949-03-30 76 76.93425 50
-#> 7 1996-06-23 29 29.70137 3
-#> 8 1963-09-16 62 62.46849 36
-#> 9 1952-05-16 73 73.80548 47
-#> 10 1952-11-14 73 73.30685 47
+#> 1 1999-06-30 26 26.68493 0
+#> 2 1968-01-29 58 58.10137 31
+#> 3 1965-12-05 60 60.25205 34
+#> 4 1980-03-01 46 46.01644 19
+#> 5 1949-11-01 76 76.34521 50
+#> 6 1947-02-14 79 79.05753 52
+#> 7 1940-02-19 86 86.04384 59
+#> 8 1988-01-10 38 38.15342 11
+#> 9 1997-08-27 28 28.52603 2
+#> 10 1978-01-26 48 48.10959 21