library(haven)
library(metacore)
library(magrittr)
load(metacore_example("pilot_ADaM.rda"))
spec <- metacore %>% select_dataset("ADSL")
data <- read_xpt(metatools_example("adsl.xpt"))
get_bad_ct(data, spec, "DISCONFL")
get_bad_ct(data, spec, "DISCONFL", na_acceptable = FALSE)
Run the code above in your browser using DataLab