1
0
mirror of https://github.com/msberends/AMR.git synced 2025-07-08 18:01:50 +02:00

MDRO, freq tables, new print format for tibbles

This commit is contained in:
2018-04-18 12:24:54 +02:00
parent 3165c50d06
commit 2509e2413d
23 changed files with 1453 additions and 85 deletions

View File

@ -0,0 +1,16 @@
context("mdro.R")
test_that("MDRO works", {
library(dplyr)
outcome <- MDRO(septic_patients, "nl", info = FALSE)
# check class
expect_equal(outcome %>% class(), c('ordered', 'factor'))
# septic_patients should have these finding using Dutch guidelines
expect_equal(outcome %>% freq(toConsole = FALSE) %>% pull(Count), c(1152, 824, 3, 21))
expect_equal(BRMO(septic_patients, info = FALSE), MDRO(septic_patients, "nl", info = FALSE))
})