View source: R/dictGenerator.R
dictGenerator | R Documentation |
This function allows you to create a dictionary from Sensata's data exported from Mongo.
dictGenerator(
df,
cols = c("qid", "identifier", "question", "type", "options", "numberOfOptions",
"isOrdered", "isSorting", "maxResponses", "altOption"),
expandOptions = TRUE,
questionPrefix = "",
forceOrdered = NULL,
responseType = "newResponses"
)
df |
data downloaded from Mongo and loaded to R |
cols |
columns to create on the dictionary. |
expandOptions |
logical. If TRUE, the dictionary will have one row per answer option. if FALSE, it will be 1 row per question. |
questionPrefix |
character that identifies questions if not included in contentful. Default "". |
forceOrdered |
vector of ordered questions that are from a non-ordered types |
responseType |
which object version should the function use, one of "newResponses" or "structuredResponses" |
Dataframe dictionary useful for data cleaning
Camilo Delvasto camilo@sensata.io & Gabriel N. Camargo-Toledo gcamargo@sensata.io
dictGenerator(data = demoData, expandOptions = F)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.