Learn R Programming

eatGADS (version 1.1.1)

emptyTheseVariables: Set variables to NA.

Description

Set all values within one or multiple variables to NA.

Usage

emptyTheseVariables(GADSdat, vars, label_suffix = "")

Value

Returns the recoded GADSdat.

Arguments

GADSdat

A GADSdat object.

vars

Character vector of variable names which should be set to NA.

label_suffix

Suffix added to variable labels for the affected variables in the GADSdat.

Examples

Run this code
# empty multiple variables
pisa2 <- emptyTheseVariables(pisa, vars = c("idstud", "idschool"))

Run the code above in your browser using DataLab