View source: R/recode_labels.R
recode_labels | R Documentation |
Convert between values and labels for factor-type variables (e.g. yes/no, radio, dropdown, checkbox)
recode_labels(
x,
conn,
dict = redcap::meta_dictionary(conn, add_complete = TRUE),
convert_to = c("labels", "values"),
types = c("radio", "yesno", "dropdown", "checkbox"),
header_labs = FALSE
)
x |
Data frame representing a REDCap form (e.g. from a previous export
using |
conn |
A REDCap API connection object (created with |
dict |
REDCap metadata dictionary. Defaults to fetching the current
version with |
convert_to |
Convert values to labels ("labels") or labels to values ("values") |
types |
Types of REDCap variables to convert, based on column
"field_type" in the metadata dictionary. Defaults to |
header_labs |
Logical indicating whether column names of |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.