Skip to content

Convert empty strings into missing values

Usage

zap_empty(x)

Arguments

x

A character vector

Value

A character vector with empty strings replaced by missing values.

Examples

x <- c("a", "", "c")
zap_empty(x)
#> [1] "a" NA  "c"