Hello,
I have been working with a few datasets and want to create a table of responses, stratified by a variable. This has worked with all datasets except for one, and I'm not sure why. My data is called "december data" and the variable I want to stratify is "agency." I also created a list called "myvars" of all my variables, and "CatVars" for my categorical variables. I have checked that these are all accurate. When I create a tableone without stratifiers, it works, but as soon as I include strata into the code, it does not work. Here is my code:
tablea <- CreateTableOne(vars = myvars, factorVars = catVars, strata = "agency", data = decemberdata)
tablea
Thank you to anyone who may be able to assist!