mdl_vars_create_from_dataframe | R Documentation |
Starting from a data frame, this function will create the variables metadata for a given survey. The function will calculate for each variable the main stats and get the variable labels when available. Labels must be set to the data frame using the labelled::var_label function or the data frame must be imported from a Stata file using the haven::read_dta function.
mdl_vars_create_from_dataframe(
survey_idno,
data_frame,
file_id,
file_name,
file_description
)
survey_idno |
The unique identifier of an existing survey, e.g.: UNHCR_ETH_2020_SENS_v2.1 |
data_frame |
A data frame containing the data. |
file_id |
An unique identifier for the file containing the variables metadata. If not provided, the name of the file will be used. If provided, the ID should only include alphanumeric chars. This ID is not shown in the platform, it is mostly used for fetching or modifying the metadata in a second moment. |
file_name |
The name of the file containing the variables as you want it to be shown in the platform to the final user. |
file_description |
Brief description of the file, as you want it to be shown in the platform to the final user. |
API call response.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.