I am using the 2015 BRFSS data to mimic this example this example. Getting the diabetes prevalence, etc. works with group_by()
as shown in Yakota's code. However, what if I need for each state, diabetes prevalence by race?
i think you want
svyby(
~ diabetes_yes_no_variable ,
~ state_variable + race_variable ,
your_survey_design ,
svymean
)