This class represents a survey object with various attributes and methods to manage survey data, design, steps, recipes, and workflows.
Public fields
data
The survey data.
edition
The edition of the survey.
type
The type´ of the survey.
periodicity
The periodicity of the survey.
default_engine
The default engine used for the survey.
weight
The weight(s) associated with the survey.
steps
A list of steps applied to the survey.
recipes
A list of recipes associated with the survey.
workflows
A list of workflows associated with the survey.
design
The survey design object(s).
active
A list of active bindings for dynamic properties of the survey.
Methods
Method new()
Initialize a new Survey object.
Usage
Survey$new(
data,
edition,
type,
psu,
engine,
weight,
design = NULL,
steps = NULL,
recipes = list()
)
Arguments
data
The survey data.
edition
The edition of the survey.
type
The type of the survey.
psu
Primary sampling unit (PSU).
engine
The engine used for the survey.
weight
The weight(s) for the survey.
design
Optional survey design.
steps
Optional list of steps.
recipes
Optional list of recipes.
Get the edition of the survey.
Returns
The survey edition.
Get the type of the survey.
Set the survey data.
Arguments
data
The new survey data.
Set the edition of the survey.
Usage
Survey$set_edition(edition)
Arguments
edition
The new survey edition.
Set the type of the survey.
Arguments
type
The new survey type.
Set the weight(s) for the survey.
Usage
Survey$set_weight(weight)
Arguments
weight
The new weight(s).
Print metadata of the survey.
Method add_step()
Add a step to the survey.
Method add_recipe()
Add a recipe to the survey.
Arguments
recipe
The recipe to add.
bake
Whether to bake the recipe immediately.
Method add_workflow()
Add a workflow to the survey.
Usage
Survey$add_workflow(workflow)
Arguments
workflow
The workflow to add.
Method bake()
Bake all recipes in the survey.
Display the first few rows of the survey data.
Display the structure of the survey data.
Method set_design()
Set the survey design.
Usage
Survey$set_design(design)
Arguments
design
The new survey design.
Method update_design()
Update the survey design based on the current data and weights.
Method clone()
The objects of this class are cloneable with this method.
Usage
Survey$clone(deep = FALSE)
Arguments
deep
Whether to make a deep clone.