zipcode_spacer(x, remove = FALSE)
Zip-code. Number or character. Hyphens may be included, but the input must contain a 7-character number.
Default is FALSE
. If TRUE
, remove the hyphen.
zipcode_spacer(7000027)
#> [1] "700-0027"
zipcode_spacer("305-0053")
#> [1] "305-0053"
zipcode_spacer("305-0053", remove = TRUE)
#> [1] "3050053"