ramses-antibiotics / ramses-package

R Package for Data-Driven Antimicrobial Stewardship & Surveillance in Hospitals
https://ramses-antibiotics.web.app/
GNU General Public License v3.0
10 stars 1 forks source link

validate_prescription #60

Closed peterdutey closed 2 years ago

peterdutey commented 3 years ago
validate_prescriptions(rxval)
 Error in `[.data.table`(data, , var) : 
  j (the 2nd argument inside [...]) is a single symbol but column name 'var' is not found. Perhaps you intended DT[, ..var]. This difference to data.frame is deliberate and explained in FAQ 1.1. 
7.
stop("j (the 2nd argument inside [...]) is a single symbol but column name '", 
    jsubChar, "' is not found. Perhaps you intended DT[, ..", 
    jsubChar, "]. This difference to data.frame is deliberate and explained in FAQ 1.1.") 
6.
`[.data.table`(data, , var) at validate_data.R#143
5.
data[, var] at validate_data.R#143
4.
FUN(X[[i]], ...) 
3.
vapply(vectorname, function(var, data) {
    any(is.na(data[, var]))
}, data = data, FUN.VALUE = logical(1)) at validate_data.R#140
2.
.validate_variable_no_missing(data = data, vectorname = variable_exists_non_missing, 
    action = "error") at validate_data.R#765
1.
validate_prescriptions(rxval) 
peterdutey commented 2 years ago

Couldn't reproduce bug