Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

zap_empty

Convert empty strings into missing values.


Description

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.

See Also

Other zappers: zap_formats(), zap_labels(), zap_label(), zap_widths()

Examples

x <- c("a", "", "c")
zap_empty(x)

haven

Import and Export 'SPSS', 'Stata' and 'SAS' Files

v2.4.1
MIT + file LICENSE
Authors
Hadley Wickham [aut, cre], Evan Miller [aut, cph] (Author of included ReadStat code), RStudio [cph, fnd]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.