z22_decode | R Documentation |
Replace category codes with their labels.
z22_decode(codes, feature, lang = c("english", "german"))
codes |
A vector of character codes, possibly prefixed with
|
feature |
A grid feature that the category |
lang |
Specifies the language of the output description. Can be
either |
.data
with category codes decoded to labels.
# retrieves a the translation of cat codes directly
z22_decode(1, "marital_status")
# recycles codes
z22_decode(c(1, 1, 1), "marital_status")
# undefined codes are returned as NA
z22_decode(c(1, 2, 3), feature = "sex")
# special case: cat_* strings
z22_decode("cat_2", feature = "sex")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.