labelled (version 2.7.0)

nolabel_to_na: Recode values with no label to NA

Description

For labelled variables, values with no label will be recoded to NA.

Usage

nolabel_to_na(x)

Arguments

x

Object to recode.

Examples

Run this code
# NOT RUN {
v <- labelled(c(1, 2, 9, 1, 9), c(yes = 1, no = 2))
nolabel_to_na(v)
# }

Run the code above in your browser using DataCamp Workspace