1
0
mirror of https://github.com/msberends/AMR.git synced 2025-07-12 19:41:58 +02:00

(v1.7.1.9070) Better WHONET support

This commit is contained in:
2021-12-13 10:18:28 +01:00
parent f90e27c1b0
commit 578e7dfee9
74 changed files with 20758 additions and 47402 deletions

2
R/ab.R
View File

@ -155,7 +155,7 @@ as.ab <- function(x, flag_multiple_results = TRUE, info = interactive(), ...) {
x[known_codes_atc],
function(x_) which(vapply(FUN.VALUE = logical(1),
AB_lookup$atc,
function(atc) x_ %in% atc)),
function(atc) x_ %in% atc))[1L],
USE.NAMES = FALSE)]
x_new[known_codes_cid] <- AB_lookup$ab[match(x[known_codes_cid], AB_lookup$cid)]
already_known <- known_names | known_codes_ab | known_codes_atc | known_codes_cid