View source: R/helper_functions.R
ed2_expand_long | R Documentation |
Expand multiple-response fields into long data form
ed2_expand_long(df, col, other_details = TRUE)
df |
The data frame containing the field to expand |
col |
The column name to split into long form |
other_details |
Whether other category should be consolidated and a new column with other details added. Defaults to TRUE. |
A long form dataframe with col
field separated into repeated entries.
## Not run: humans <- ed2_human() humans_reduced <- dplyr::select(humans, event_name, participant_id, travel_reason) humans_reduced_long <- ed2_expand_long(humans_reduced, travel_reason) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.