M
y dataset includes a survey completed by research participants to evaluate
quality of life. A few things regarding the survey:
-
*not all questions must be answered for the total score *
- questions left blank are coded as "0"
- the number of questions answered must be determined in order to
compute the total score
*Sample Code*
q1 <- ifelse(is.na(survey, 0, survey$q1)
q2 <- ifelse(is.na(survey, 0, survey$q2)
q3 <- ifelse(is.na(survey, 0, survey$q3)
survey$sum.survey <- q1 + q2 + q3
survey$responses <- # HELP ?????
*> # HELP PART 1 ------------------------------*
*> # need help determining number of questions the respondents answered*
*# HELP PART 2 -------------------------------*
*> # I want to look at the subset of the population that completed all the
questions*
Thanks for your help!! It means a lot :)
[[alternative HTML version deleted]]