Learn R Programming

surveycore (version 0.8.3)

survey_weighting_history: Extract the Weighting History from a Survey Object

Description

Returns the list of weighting operations recorded on a survey design object. Each entry is appended by surveywts after a calibration or nonresponse adjustment step. Returns an empty list when no history has been recorded.

Usage

survey_weighting_history(x)

Value

A list of history entries, or list() if no history is present.

Arguments

x

A survey design object (any class inheriting from survey_base).

See Also

Other metadata: classify_question_type(), extract_metadata(), extract_missing_codes(), extract_question_preface(), extract_sata(), extract_universe(), extract_val_labels(), extract_var_label(), extract_var_note(), infer_question_prefaces(), set_missing_codes(), set_question_preface(), set_sata(), set_universe(), set_val_labels(), set_var_label(), set_var_note(), survey_metadata()

Examples

Run this code
d <- as_survey(nhanes_2017, ids = sdmvpsu, weights = wtint2yr,
               strata = sdmvstra, nest = TRUE)
survey_weighting_history(d)   # list() — no weighting history

Run the code above in your browser using DataLab