I am analyzing data from a "Select all that apply" question and want to create a summary table of each response. When exporting data, my df looks like this:
q1_option1 <- c("1", "0", "1", "0")
q1_option2 <- c("0", "0", "1", "1")
q1_option3 <- c("1", "1", "1", "1")
df <- data.frame(option1, option2, option3)
And I would like to create summary tables like:
yes (%) no (%)
q1_option1 2 (50%) 2 (50%)
q1_option2 2 (50%) 2 (50%)
q1_option3 4 (100%) 0
I feel like this should be a simple solution but I've spent all day trying to find an answer.