1
0
mirror of https://github.com/msberends/AMR.git synced 2026-02-10 03:12:53 +01:00

(v3.0.1.9020) unit test fixes

This commit is contained in:
2026-02-09 13:16:36 +01:00
parent ba4c159154
commit 499c830ee7
9 changed files with 42 additions and 30 deletions

View File

@@ -314,7 +314,9 @@ antimicrobials_equal <- function(y,
key2sir <- function(val) {
val <- strsplit(val, "", fixed = TRUE)[[1L]]
as.double(as.sir(val))
val.int <- rep(NA_real_, length(val))
val.int[val %in% VALID_SIR_LEVELS] <- as.double(as.sir(val[val %in% VALID_SIR_LEVELS]))
val.int
}
# only run on uniques
uniq <- unique(c(y, z))