Sets the question preface string for one or more variables. Question prefaces are the shared introductory text for a battery of related questions.
Details
Supports Conventions 1, 2, and 3 — see set_var_label() for details.
See also
extract_question_preface() to retrieve a preface
Other metadata:
extract_metadata(),
extract_missing_codes(),
extract_question_preface(),
extract_universe(),
extract_val_labels(),
extract_var_label(),
extract_var_note(),
infer_question_prefaces(),
set_missing_codes(),
set_universe(),
set_val_labels(),
set_var_label(),
set_var_note(),
survey_metadata(),
survey_weighting_history()
Examples
d <- as_survey(gss_2024, ids = vpsu, weights = wtssps,
strata = vstrat, nest = TRUE)
d <- set_question_preface(d, happy = "Taken all together...")
extract_question_preface(d, happy)
#> happy
#> "Taken all together..."
