Learn R Programming

catSurv (version 1.1.3)

readQualtrics: Clean adaptive inventory responses from Qualtrics

Description

This function cleans the adaptive inventory responses stored as embedded data in Qualtrics

Usage

# S4 method for character
readQualtrics(catObj, responseID)

Arguments

catObj

Vector containing JSON character representations of the completed Cat objects from Qualtrics survey

responseID

Vector containing unique character identifiers for the respondents in the Qualtrics survey

Value

This function returns a data frame containing cleaned adaptive inventory responses.

Details

This function cleans the adaptive inventory responses contained in the Qualtrics survey results. Because different respondents recieve different adaptive inventories, their answers to the battery are not stored as usual as separate columns in the Data & Analysis tab in the Qualtrics toolbar. Rather, the respondents' answers to the adaptive battery are saved in the catObj embedded data object. To access the answers, click "Export & Import", and then "Export Data." In the window that appears, we recommend downloading the data as a .csv file. Then, feed this function the catObj column and the responseID column.

See Also

Cat-class

Examples

Run this code
# NOT RUN {
# }
# NOT RUN {
raw_df <- read.csv("qualtrics_results.csv", stringsAsFactors = FALSE)

# removing first two header rows containing question text and import ID
clean_df <- readQualtrics(raw_df$catObj[-c(1,2)], raw_df$catObj[-c(1,2)])
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab