# \donttest{
if (requireNamespace("haven", quietly = TRUE)) {
# Tag -9/-8 as missing, then recover the original codes
x <- set_na(c(1, 2, -9, 3, -8), -9, -8)
untag_na(x) # -9 and -8 are back
}
# }
Run the code above in your browser using DataLab