# NOT RUN {
longdf <- icd_long_data(
visit = c("a", "b", "b", "c"),
icd9 = c("441", "4240", "443", "441")
)
cmbdf <- icd9_comorbid_elix(longdf, return_df = TRUE)
class(cmbdf)
rownames(cmbdf)
mat.out <- comorbid_df_to_mat(cmbdf)
stopifnot(is.matrix(mat.out))
mat.out[, 1:4]
# }
Run the code above in your browser using DataLab