1
0
mirror of https://github.com/msberends/AMR.git synced 2025-07-08 09:11:51 +02:00

(v1.4.0.9016) as.rsi() older R versions

This commit is contained in:
2020-11-10 19:59:14 +01:00
parent 15c732703d
commit 68ac39aa7f
14 changed files with 28 additions and 17 deletions

View File

@ -46,7 +46,7 @@ test_that("mdro works", {
library(dplyr)
# example_isolates should have these finding using Dutch guidelines
expect_equal(outcome %>% cleaner::freq() %>% pull(count),
expect_equal(as.double(table(outcome)),
c(1969, 25, 6)) # 1969 neg, 25 unconfirmed, 6 pos
expect_equal(brmo(example_isolates, info = FALSE),
@ -104,7 +104,7 @@ test_that("mdro works", {
expect_equal(
# select only rifampicine, mo will be determined automatically (as M. tuberculosis),
# number of mono-resistant strains should be equal to number of rifampicine-resistant strains
cleaner::freq(mdr_tb(example_isolates[, "RIF", drop = FALSE]))$count[2],
as.double(table(mdr_tb(example_isolates[, "RIF", drop = FALSE])))[2],
count_R(example_isolates$RIF))
sample_rsi <- function() {