From 035891851da6cfec83a988a17dc11b1c1b5e8b81 Mon Sep 17 00:00:00 2001 From: Isabella Velasquez Date: Mon, 19 Aug 2024 19:56:13 -0500 Subject: [PATCH] Edit question text --- 14-ambarom-vignette.Rmd | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/14-ambarom-vignette.Rmd b/14-ambarom-vignette.Rmd index 807c0a3..eb2415e 100644 --- a/14-ambarom-vignette.Rmd +++ b/14-ambarom-vignette.Rmd @@ -173,16 +173,14 @@ When calculating estimates from the data, we use the survey design object `ambar ### Example: Worry about COVID-19 -This survey was administered between March and August 2021, with the specific timing varying by country^[See table 2 in @lapop-tech for dates by country]. Given the state of the pandemic at that time, several questions about COVID-19 were included. The first question about COVID-19 asked was: +This survey was administered between March and August 2021, with the specific timing varying by country^[See table 2 in @lapop-tech for dates by country]. Given the state of the pandemic at that time, several questions about COVID-19 were included. According to the core questionnaire [@lapop-svy], the first question asked about COVID-19 was: -> Question text: "How worried are you about the possibility that you or someone in your household will get sick from coronavirus in the next 3 months?" +> "How worried are you about the possibility that you or someone in your household will get sick from coronavirus in the next 3 months?" > > | - Very worried > | - Somewhat worried > | - A little worried > | - Not worried at all -> -> Source: [@lapop-svy] If we are interested in those who are very worried or somewhat worried, we can create a new variable (`CovidWorry_bin`) that groups levels of the original question using the `fct_collapse()` function from the {forcats} package [@R-forcats]. We then use the `survey_count()` function to understand how responses are distributed across each category of the original variable (`CovidWorry`) and the new variable (`CovidWorry_bin`). \index{Functions in srvyr!survey\_count|(} @@ -244,17 +242,15 @@ covid_worry_country_ests_gt %>% ### Example: Education affected by COVID-19 -Respondents were also asked a question about how the pandemic affected education. This question was asked to households with children under the age of 13, and respondents could select more than one option, as follows: +In the core questionnaire [@lapop-svy], respondents were also asked a question about how the pandemic affected education. This question was asked to households with children under the age of 13, and respondents could select more than one option, as follows: -> Question text: "Did any of these children have their school education affected due to the pandemic?" +> "Did any of these children have their school education affected due to the pandemic?" > > | - No, because they are not yet school age or because they do not attend school for another reason > | - No, their classes continued normally > | - Yes, they went to virtual or remote classes > | - Yes, they switched to a combination of virtual and in-person classes > | - Yes, they cut all ties with the school -> -> Source: [@lapop-svy] Working with multiple-choice questions can be both challenging and interesting. Let's walk through how to analyze this question. If we are interested in the impact on education, we should focus on the data of those whose children are attending school. This means we need to exclude those who selected the first response option: "No, because they are not yet school age or because they do not attend school for another reason." To do this, we use the `Educ_NotInSchool` variable in the dataset, which has values of `0` and `1`. A value of `1` indicates that the respondent chose the first response option (none of the children are in school), and a value of `0` means that at least one of their children is in school. By filtering the data to those with a value of `0` (they have at least one child in school), we can consider only respondents with at least one child attending school.