├── .Rbuildignore ├── .gitignore ├── DESCRIPTION ├── NAMESPACE ├── QualtricsTools.Rproj ├── R ├── comment_coding.R ├── data.R ├── helper_functions.R ├── html_results.R ├── loading_files.R ├── pandoc_conversion.R ├── question_type_checking.R ├── reorganizing_survey_data.R └── results_generation.R ├── README.md ├── data ├── Sample Surveys │ ├── Better Sample Survey │ │ ├── Better_Sample_Survey.csv │ │ ├── Better_Sample_Survey.qsf │ │ ├── RDS │ │ │ ├── original_first_rows.rds │ │ │ ├── q2_favorite.rds │ │ │ └── q2_favorite_results_table.rds │ │ └── example_long_and_lean.xls │ ├── Comment Coding │ │ ├── Coded Comments │ │ │ └── Q5 Coded.xlsx │ │ ├── Test_Survey_for_Coded_Comments.csv │ │ └── Test_Survey_for_Coded_Comments.qsf │ ├── Long Exhaustive Sample Survey │ │ ├── Long_Exhaustive_Sample_Survey.csv │ │ ├── Long_Exhaustive_Sample_Survey.qsf │ │ └── RDS │ │ │ ├── Q10.rds │ │ │ ├── Q10_results_table.rds │ │ │ ├── Q11.rds │ │ │ ├── Q11_results_table.rds │ │ │ ├── Q12.rds │ │ │ ├── Q12_results_table.rds │ │ │ ├── Q13_family_food.rds │ │ │ ├── Q13_family_food_results_table.rds │ │ │ ├── Q14.rds │ │ │ ├── Q14_results_table.rds │ │ │ ├── Q15.rds │ │ │ ├── Q15_results_table.rds │ │ │ ├── Q16.rds │ │ │ ├── Q16_results_table.rds │ │ │ ├── Q2.rds │ │ │ ├── Q20.rds │ │ │ ├── Q20_results_table.rds │ │ │ ├── Q21.rds │ │ │ ├── Q21_results_table.rds │ │ │ ├── Q22.rds │ │ │ ├── Q22_results_table.rds │ │ │ ├── Q23.rds │ │ │ ├── Q23_results_table.rds │ │ │ ├── Q24.rds │ │ │ ├── Q24_results_table.rds │ │ │ ├── Q25.rds │ │ │ ├── Q25_results_table.rds │ │ │ ├── Q26.rds │ │ │ ├── Q26_results_table.rds │ │ │ ├── Q27.rds │ │ │ ├── Q27_results_table.rds │ │ │ ├── Q29.rds │ │ │ ├── Q29_results_table.rds │ │ │ ├── Q2_results_table.rds │ │ │ ├── Q3.rds │ │ │ ├── Q31.rds │ │ │ ├── Q31_results_table.rds │ │ │ ├── Q32.rds │ │ │ ├── Q32_results_table.rds │ │ │ ├── Q33.rds │ │ │ ├── Q33_results_table.rds │ │ │ ├── Q34.rds │ │ │ ├── Q34_results_table.rds │ │ │ ├── Q35.rds │ │ │ ├── Q35_results_table.rds │ │ │ ├── Q36.rds │ │ │ ├── Q36_results_table.rds │ │ │ ├── Q37.rds │ │ │ ├── Q37_results_table.rds │ │ │ ├── Q3_results_table.rds │ │ │ ├── Q5.rds │ │ │ ├── Q5_results_table.rds │ │ │ ├── Q6.rds │ │ │ ├── Q6_results_table.rds │ │ │ ├── Q7.rds │ │ │ ├── Q7_results_table.rds │ │ │ ├── Q8.rds │ │ │ ├── Q8_results_table.rds │ │ │ ├── Q9.rds │ │ │ ├── Q9_results_table.rds │ │ │ ├── original_first_rows.rds │ │ │ ├── q30_cooking_style.rds │ │ │ ├── q30_cooking_style_results_table.rds │ │ │ ├── q4_colored_fruit.rds │ │ │ └── q4_colored_fruit_results_table.rds │ ├── Many Different Question Types │ │ ├── Sample_Survey (Insights).csv │ │ ├── Sample_Survey.csv │ │ └── Sample_Survey.qsf │ ├── Matrix Single Answer Survey │ │ ├── Matrix_Single_Answer_Testing.csv │ │ └── Matrix_Single_Answer_Testing.qsf │ ├── Multiple Answer Matrix Questions │ │ ├── Insights vs Pre-Insights Headers.xlsx │ │ ├── Multiple_Answer_Matrix_Questions (Insights).csv │ │ ├── Multiple_Answer_Matrix_Questions.csv │ │ └── Multiple_Answer_Matrix_Questions.qsf │ ├── Multiple Answer Multiple Choices Questions │ │ ├── Insight vs Pre-Insight Headers.xlsx │ │ ├── Multiple_Answer_MC_Questions (Insights).csv │ │ ├── Multiple_Answer_MC_Questions.csv │ │ └── Multiple_Answer_MC_Questions.qsf │ ├── No Basis for Evaluation │ │ ├── No_Basis_for_Evaluation (Insights).csv │ │ ├── No_Basis_for_Evaluation (Legacy).csv │ │ └── No_Basis_for_Evaluation.qsf │ ├── Sample Coded Comments │ │ └── Q5 Coded.xlsx │ ├── Sample Survey │ │ ├── Sample_Survey.csv │ │ └── Sample_Survey.qsf │ ├── Side-by-Side Questions │ │ ├── Side-by-Side_Questions.qsf │ │ ├── SidebySide_Questions (Insights).csv │ │ └── SidebySide_Questions (Legacy).csv │ ├── Single Answer Matrix Questions │ │ ├── Insights vs Pre-Insights Headers.xlsx │ │ ├── Single_Answer_Matrix_Questions (Insights).csv │ │ ├── Single_Answer_Matrix_Questions.csv │ │ └── Single_Answer_Matrix_Questions.qsf │ ├── Single Answer Multiple Choice Questions │ │ ├── Insights vs Pre-Insights Headers.xlsx │ │ ├── Single_Answer_MC_Questions (Insights).csv │ │ ├── Single_Answer_MC_Questions.csv │ │ └── Single_Answer_MC_Questions.qsf │ ├── Survey Logic │ │ ├── Survey_Logic_EVERYWHERE.csv │ │ ├── Survey_Logic_EVERYWHERE.docx │ │ ├── Survey_Logic_EVERYWHERE.qsf │ │ └── results_tables.docx │ ├── Test Getting Choice Text from Response Columns │ │ ├── Choice_Text_from_Response_Columns.csv │ │ └── Choice_Text_from_Response_Columns.qsf │ ├── Text Entry Components │ │ ├── Questions_with_Text_Entry_Components.csv │ │ └── Questions_with_Text_Entry_Components.qsf │ └── User Notes Survey │ │ ├── Notes_Survey.csv │ │ └── Notes_Survey.qsf ├── sample_original_first_rows.rda ├── sample_responses.rda └── sample_survey.rda ├── inst ├── shiny │ ├── server.R │ ├── ui.R │ └── www │ │ ├── custom.css │ │ └── custom.js └── testdata │ ├── Sample_Survey.csv │ ├── Sample_Survey.qsf │ ├── plain_matrix_ma.RDS │ ├── plain_mcma.RDS │ ├── plain_mcsa.RDS │ ├── recode_mcma.RDS │ ├── recode_mcsa.RDS │ └── recode_na_matrix_sa.RDS ├── man ├── answers_from_response_column.Rd ├── app.Rd ├── appendix_lettering.Rd ├── ask_for_csv.Rd ├── ask_for_qsf.Rd ├── blocks_from_survey.Rd ├── blocks_header_to_html.Rd ├── choice_text_from_question.Rd ├── choice_text_from_response_column.Rd ├── clean_html.Rd ├── clean_question_text.Rd ├── create_html_results_tables.Rd ├── create_merged_response_column.Rd ├── create_panel_data.Rd ├── create_question_dictionary.Rd ├── create_response_column_dictionary.Rd ├── create_response_lookup_table.Rd ├── directory_get_coded_comment_sheets.Rd ├── display_logic_from_question.Rd ├── find_question.Rd ├── find_question_index.Rd ├── find_question_index_by_qid.Rd ├── flow_from_survey.Rd ├── format_and_split_comment_sheets.Rd ├── format_coded_comment_sheets.Rd ├── format_coded_comments.Rd ├── generate_results.Rd ├── get_coded_comment_sheet.Rd ├── get_reorganized_questions_and_blocks.Rd ├── get_setup.Rd ├── get_setup_in_environment.Rd ├── html_2_pandoc.Rd ├── human_readable_qtype.Rd ├── insert_coded_comments.Rd ├── insert_notes_into_questions.Rd ├── insert_split_survey_comments.Rd ├── is_matrix_bipolar.Rd ├── is_matrix_multiple_answer.Rd ├── is_matrix_question.Rd ├── is_matrix_single_answer.Rd ├── is_mc_multiple_answer.Rd ├── is_mc_single_answer.Rd ├── is_multiple_answer.Rd ├── is_rank_order.Rd ├── is_single_answer.Rd ├── is_text_entry.Rd ├── lean_responses.Rd ├── link_responses_to_questions.Rd ├── load_csv_data.Rd ├── load_qsf_data.Rd ├── make_coded_comments.Rd ├── make_results_tables.Rd ├── make_split_coded_comments.Rd ├── make_split_results_tables.Rd ├── make_split_text_appendices.Rd ├── make_text_appendices.Rd ├── matrix_multiple_answer_results.Rd ├── matrix_single_answer_results.Rd ├── mc_multiple_answer_results.Rd ├── mc_single_answer_results.Rd ├── merge_split_column_into_comment_sheet.Rd ├── notes_from_survey.Rd ├── number_of_blocks.Rd ├── percent0.Rd ├── process_question_results.Rd ├── question_description.Rd ├── question_from_response_column.Rd ├── question_variable_to_choice_text.Rd ├── questions_from_blocks.Rd ├── questions_from_survey.Rd ├── questions_into_blocks.Rd ├── remove_trash_blocks.Rd ├── remove_trash_questions.Rd ├── repath.Rd ├── sample_responses.Rd ├── sample_survey.Rd ├── split_respondents.Rd ├── split_side_by_sides.Rd ├── tabelize_display_logic.Rd ├── table_html_coded_comments.Rd ├── table_mcsa_multitext.Rd ├── table_no_respondents.Rd ├── table_non_text_entry.Rd ├── table_text_entry.Rd ├── text_appendices_table.Rd ├── uncodeable_question_dictionary.Rd ├── uncodeable_questions_message.Rd ├── validate_data_export_tags.Rd └── which_choices_have_text_entry.Rd ├── pics ├── animation.gif ├── display logic.png ├── include exclude questions.png ├── more options.png ├── question dictionary.png ├── results tables.png └── text appendices.png ├── tests ├── testthat.R └── testthat │ ├── test_comment_coding.R │ ├── test_matrix_ma_question_processing.R │ ├── test_matrix_sa_question_processing.R │ ├── test_mcma_question_processing.R │ ├── test_mcsa_question_processing.R │ ├── test_reorganizing_survey_data.R │ ├── test_results_reports.R │ └── test_text_appendices.R └── vignettes ├── Comment-Coding.Rmd ├── Finding-Question-Information.Rmd ├── Finding-Undocumented-Parameters.Rmd ├── Generate-Results-Tables.Rmd ├── Managing-an-R-Package.Rmd ├── Recode-Values.Rmd ├── Sample-Surveys.Rmd ├── Source-Code-Layout.Rmd └── The-Structure-of-the-QSF.Rmd /.Rbuildignore: -------------------------------------------------------------------------------- 1 | ^.*\.Rproj$ 2 | ^\.Rproj\.user$ 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .Rproj.user 2 | .Rhistory 3 | .RData 4 | .Ruserdata 5 | *~ 6 | .vscode 7 | *.swp 8 | inst/doc 9 | -------------------------------------------------------------------------------- /DESCRIPTION: -------------------------------------------------------------------------------- 1 | Package: QualtricsTools 2 | Type: Package 3 | Title: Automating Qualtrics Survey Processing 4 | Version: 0.1.0 5 | Author: Christian Testa 6 | Maintainer: Christian Testa 7 | Description: This package is for automating the processing of Qualtrics surveys. 8 | The Shiny app included serves as an easy-to-use interface for generating reports 9 | from survey data from Qualtrics. Further, other functions allow the user to 10 | generate data frames detailing the questions or the responses in a long data 11 | format. 12 | License: BSD 13 | LazyData: true 14 | Imports: 15 | digest, 16 | dplyr, 17 | gdata, 18 | gtools, 19 | htmltools, 20 | httpuv, 21 | magrittr, 22 | plyr, 23 | reshape, 24 | readxl, 25 | rjson, 26 | Rcpp, 27 | shiny, 28 | shinydashboard, 29 | tidyr, 30 | xtable, 31 | XML 32 | Suggests: 33 | testthat, 34 | knitr, 35 | rmarkdown 36 | VignetteBuilder: knitr 37 | Remotes: talgalili/installr 38 | RoxygenNote: 6.0.1 39 | -------------------------------------------------------------------------------- /NAMESPACE: -------------------------------------------------------------------------------- 1 | exportPattern("^[[:alpha:]]+") 2 | importFrom(gdata, startsWith) 3 | import(shiny) 4 | import(shinydashboard) 5 | import(rjson) 6 | -------------------------------------------------------------------------------- /QualtricsTools.Rproj: -------------------------------------------------------------------------------- 1 | Version: 1.0 2 | 3 | RestoreWorkspace: No 4 | SaveWorkspace: No 5 | AlwaysSaveHistory: Yes 6 | 7 | EnableCodeIndexing: Yes 8 | UseSpacesForTab: Yes 9 | NumSpacesForTab: 2 10 | Encoding: UTF-8 11 | 12 | RnwWeave: Sweave 13 | LaTeX: pdfLaTeX 14 | 15 | AutoAppendNewline: Yes 16 | StripTrailingWhitespace: Yes 17 | 18 | BuildType: Package 19 | PackageUseDevtools: Yes 20 | PackageInstallArgs: --no-multiarch --with-keep.source 21 | PackageRoxygenize: rd,collate,namespace 22 | -------------------------------------------------------------------------------- /R/data.R: -------------------------------------------------------------------------------- 1 | #' Sample Qualtrics Survey Data 2 | #' 3 | #' This is a sample survey, with a couple questions of different types. 4 | #' 5 | "sample_survey" 6 | 7 | #' Sample Qualtrics Response Data 8 | #' 9 | #' This is some sample response data, to the matching sample survey provided 10 | "sample_responses" 11 | -------------------------------------------------------------------------------- /R/loading_files.R: -------------------------------------------------------------------------------- 1 | requireNamespace("rjson") 2 | 3 | #' Set Response Data to Sample Data or User Data 4 | #' 5 | #' load_csv_data returns the sample response set or the user's response set depending 6 | #' on whether or not the user has uploaded data. 7 | #' 8 | #' @param file1 This should be a CSV received from a file upload made in the Shiny UI, 9 | #' which includes a file1[['datapath']] where the data can be located. 10 | #' 11 | #' 12 | #' @return The return value is the responses data frame 13 | load_csv_data <- function(file2, file1, headerrows) { 14 | if (is.null(file2) && is.null(file1)) { 15 | responses <- list(sample_responses, sample_original_first_rows) 16 | } else if (is.null(file2)) { 17 | responses <- NULL 18 | } else { 19 | responses <- ask_for_csv(file2[['datapath']], headerrows) 20 | } 21 | return(responses) 22 | } 23 | 24 | #' Set Survey to Sample Survey or User Survey 25 | #' 26 | #' load_qsf_data returns the sample survey 27 | #' or the user's survey depending 28 | #' on whether or not the user has uploaded data. 29 | #' 30 | #' @param file2 This should be a QSF file received 31 | #' from a file upload made in the Shiny UI, 32 | #' which includes a file1[['datapath']] where the data can be located. 33 | #' 34 | #' @return The return value is the survey list object 35 | 36 | load_qsf_data <- function(file1) { 37 | if (is.null(file1)) { 38 | survey <- sample_survey 39 | } else { 40 | survey <- ask_for_qsf(file1[['datapath']]) 41 | } 42 | } 43 | 44 | 45 | #' Ask the user for the Qualtrics Survey file 46 | #' 47 | #' This function can be provided the path to a 48 | #' Qualtrics survey as its parameter, or 49 | #' the function will prompt the user to specify 50 | #' the path to the file. 51 | #' 52 | #' 53 | #' @param surveyfile The file path to a Qualtrics survey file 54 | #' 55 | #' @return The survey file the user uploads, as a list 56 | ask_for_qsf <- function(surveyfile) { 57 | if (missing(surveyfile)) { 58 | cat("Select Qualtrics Survey File:") 59 | surveyfile = file.choose() 60 | } 61 | survey = rjson::fromJSON(file=surveyfile) 62 | 63 | return(survey) 64 | } 65 | 66 | #' Ask the user for the Qualtrics Response Set 67 | #' 68 | #' ask_for_csv() inputs a file and a number of headerrows and returns a 69 | #' list containing a responses data frame, and a 1-2 row data frame of the 70 | #' responses' headers. Both input parameters are optional in the sense that 71 | #' they do not have to be provided inline to the function, and that the 72 | #' function will ask the user to choose a file for the responsesfile if one is 73 | #' not provided inline, and it will default to using 3 headerrows. 74 | #' 75 | #' @param responsesfile this is the file path of a CSV response set to a Qualtrics survey 76 | #' @param headerrows the number of rows before responses begin in the CSV data 77 | #' @return a list of two elements: the responses data frame, and the original_first_rows data frame 78 | ask_for_csv <- function(responsesfile, headerrows) { 79 | if (missing(responsesfile)) { 80 | cat("Select CSV Response File:") 81 | responsesfile = file.choose() 82 | } 83 | if (missing(headerrows)) { 84 | headerrows <- 3 85 | } 86 | responses = read.csv(responsesfile, check.names = FALSE, stringsAsFactors = FALSE) 87 | responses[which(colnames(responses) == "")] <- NULL 88 | original_first_rows <- responses[1:(headerrows-1),] 89 | 90 | if (headerrows == 3) { 91 | original_first_rows[2,] <- lapply(original_first_rows[2, ], function(x) { 92 | x <- gsub("^\\{'ImportId': '", "", x, perl=TRUE) 93 | x <- gsub("'\\}$", "", x, perl=TRUE) 94 | }) 95 | } 96 | 97 | responses <- responses[headerrows:nrow(responses),] 98 | responses <- responses[apply(responses, 1, function(x) any(x != "")),] 99 | responses <- as.data.frame(apply(responses, 2, trimws)) 100 | return(list(responses, original_first_rows)) 101 | } 102 | 103 | 104 | #' Validate Data Export Tag Uniqueness 105 | #' 106 | #' It is crucial for parts of this program to work that the DataExportTags be unique 107 | #' to one another. This program checks for duplicates among the DataExportTags, and 108 | #' returns a boolean statement representing whether or not the DataExportTags validated. 109 | #' validate_export_tags returns TRUE if the DataExportTags are not duplicated, and are valid, 110 | #' and FALSE if the DataExportTags did not validate, and are duplicated. 111 | #' 112 | #' @param questions A list of questions from a Qualtrics survey 113 | validate_data_export_tags <- function(questions) { 114 | dataexporttags <- sapply(questions, function(x) x[['Payload']][['DataExportTag']]) 115 | if (any(duplicated(dataexporttags))) { 116 | FALSE 117 | } else { 118 | TRUE 119 | } 120 | } 121 | -------------------------------------------------------------------------------- /R/pandoc_conversion.R: -------------------------------------------------------------------------------- 1 | #' Convert HTML to a Docx File 2 | #' 3 | #' This function uses pandoc and tempfiles to create a docx version 4 | #' of an HTML document. The HTML is prepended and appended with 5 | #' and . Then it is saved 6 | #' to a tempfile, and then pandoc converts it to a .docx file. Finally, 7 | #' the path to the .docx file is returned. 8 | #' 9 | #' @param html an html body contents string. Do not include the ... tags, 10 | #' the html parameter will automatically have those kinds of tags added within this 11 | #' function. 12 | #' @param output_dir an optional parameter for specifying an output folder 13 | #' 14 | #' @return the path to the docx file created from converting the html. 15 | html_2_pandoc <- function(html, file_name, format, output_dir) { 16 | # it is necessary that we save the file in UTF-8 format, otherwise Pandoc 17 | # will not be able to read it. 18 | options("encoding" = "UTF-8") 19 | 20 | # set default format to docx 21 | if (missing(format)) { 22 | if (missing(file_name)) { 23 | format <- "docx" 24 | } else { 25 | format <- tools::file_ext(file_name) 26 | } 27 | } 28 | 29 | # save the original working directory so we can return to it at the end. 30 | # move to the temporary files directory, use tempfile() to create 31 | # the temporary HTML document, and then the .docx file path which we will 32 | # use pandoc to generate. 33 | orig_directory <- getwd() 34 | 35 | temp_dir <- tempdir() 36 | setwd(temp_dir) 37 | html <- unlist(c("", html, "")) 38 | temp_html <- basename(tempfile(fileext = ".html")) 39 | temp_output_full <- tempfile(fileext = paste0(".", format)) 40 | temp_output <- basename(temp_output_full) 41 | write(html, file = temp_html) 42 | 43 | # create the pandoc conversion command by replacing 44 | # the "temp_html" and "temp_docx" values with their 45 | # actual values (the file names). 46 | # run the pandoc conversion, then return to the original directory, 47 | # then return the full filepath of the converted docx file. 48 | pandoc_command <- "pandoc -s temp_html -o temp_output" 49 | pandoc_command <- gsub("temp_html", temp_html, pandoc_command) 50 | pandoc_command <- gsub("temp_output", temp_output, pandoc_command) 51 | system(pandoc_command) 52 | 53 | # rename the file if a name was given 54 | if (!missing(file_name)) { 55 | file.rename(from=temp_output, to=file_name) 56 | temp_output_full <- file.path(temp_dir, file_name) 57 | } 58 | 59 | if (!missing(output_dir)) { 60 | file.rename(from=temp_output_full, to=file.path(output_dir, basename(temp_output_full))) 61 | temp_output_full <- file.path(output_dir, basename(temp_output_full)) 62 | } 63 | 64 | # make sure the path is safe for Windows 65 | temp_output_full <- gsub('\\\\', '/', temp_output_full) 66 | 67 | # set things back to normal 68 | setwd(orig_directory) 69 | options("encoding" = "native.enc") 70 | 71 | 72 | return(temp_output_full) 73 | } 74 | 75 | -------------------------------------------------------------------------------- /data/Sample Surveys/Better Sample Survey/RDS/original_first_rows.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Better Sample Survey/RDS/original_first_rows.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Better Sample Survey/RDS/q2_favorite.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Better Sample Survey/RDS/q2_favorite.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Better Sample Survey/RDS/q2_favorite_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Better Sample Survey/RDS/q2_favorite_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Better Sample Survey/example_long_and_lean.xls: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Better Sample Survey/example_long_and_lean.xls -------------------------------------------------------------------------------- /data/Sample Surveys/Comment Coding/Coded Comments/Q5 Coded.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Comment Coding/Coded Comments/Q5 Coded.xlsx -------------------------------------------------------------------------------- /data/Sample Surveys/Comment Coding/Test_Survey_for_Coded_Comments.csv: -------------------------------------------------------------------------------- 1 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Q1,Q1_TEXT,Q2,LocationLatitude,LocationLongitude,LocationAccuracy 2 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,"This question has multiple ""other please specify"" options","This question has multiple ""other please specify"" options",What's up home skillets? ,LocationLatitude,LocationLongitude,LocationAccuracy 3 | {'ImportId': 'responseId'},{'ImportId': 'responseSetId'},{'ImportId': 'ipAddress'},{'ImportId': 'startDate'},{'ImportId': 'endDate'},{'ImportId': 'panel-RecipientLastName'},{'ImportId': 'panel-RecipientFirstName'},{'ImportId': 'panel-RecipientEmail'},{'ImportId': 'panel-ExternalDataReference'},{'ImportId': 'finished'},{'ImportId': 'status'},{'ImportId': 'QID1'},{'ImportId': 'QID1-TEXT'},{'ImportId': 'QID2-TEXT'},{'ImportId': 'Location-LocationLatitude'},{'ImportId': 'Location-LocationLongitude'},{'ImportId': 'Location-LocationAccuracy'} 4 | R_bdygJsbbIhnpYz3,Default Response Set,,2016-10-06 14:28:12,2016-10-06 14:28:12,,,,,1,2,1,,Phasellus? Molestie nibh vel auctor tempor neque cursus lectus felis enim. Posuere magna. Posuere? Tempor.,42.401901245117,-71.119300842285,-1 5 | R_aWfmNJpLtsjnEFL,Default Response Set,,2016-10-06 14:28:12,2016-10-06 14:28:12,,,,,1,2,1,,"Facilisi, lorem lectus pharetra, velit mauris, montes interdum curabitur phasellus leo. Sit.",42.401901245117,-71.119300842285,-1 6 | R_0xjTuua5FYUOhFj,Default Response Set,,2016-10-06 14:28:12,2016-10-06 14:28:12,,,,,1,2,5,"Natoque wisi viverra wisi! Vel facilisis. Temporibus nibh pharetra aenean quam, montes primis.",Volutpat molestie eleifend malesuada tortor etiam et ut magnis aliquam amet ultrices amet? Nullam luctus.,42.401901245117,-71.119300842285,-1 7 | R_721xLcaILSbyvdP,Default Response Set,,2016-10-06 14:28:12,2016-10-06 14:28:12,,,,,1,2,6,Vitae tempor tincidunt rhoncus sed orci tempora. Purus? Pede porttitor blandit massa.,"Temporibus etiam pretium vivamus praesent ante montes sodales. Porta, integer aenean? Proin rhoncus.",42.401901245117,-71.119300842285,-1 8 | R_dpqJ4d4CEyKV4Hz,Default Response Set,,2016-10-06 14:28:13,2016-10-06 14:28:13,,,,,1,2,1,,Orci egestas sodales non tempora. Pretium iaculis metus eget tempora venenatis a eget.,42.401901245117,-71.119300842285,-1 9 | R_bDk3xQwWyL3RFQh,Default Response Set,,2016-10-06 14:40:56,2016-10-06 14:40:56,,,,,1,2,5,Eu. Orci posuere posuere mattis laoreet tempor vehicula vitae! Aliquam? Ultrices mattis ab. Wisi elit.,Ante? Gravida quam at? Vehicula phasellus lacus diam sollicitudin id.,42.401901245117,-71.119300842285,-1 10 | R_e38nE1332JvNGsZ,Default Response Set,,2016-10-06 14:40:57,2016-10-06 14:40:57,,,,,1,2,6,"Lectus ridiculus eleifend! Orci metus, culpa, tempus? Fermentum mauris tellus venenatis.",Gravida massa atque vehicula dolor! Atque primis velit ridiculus? Orci imperdiet scelerisque mi iaculis magna.,42.401901245117,-71.119300842285,-1 11 | R_9BtyMSaNy4V65Df,Default Response Set,,2016-10-06 14:40:57,2016-10-06 14:40:57,,,,,1,2,5,"Urna dolor. Dapibus. Tortor consequat, dolor cursus eget. Convallis tempor convallis elit.",Eu sagittis sagittis faucibus. Mi accumsan magnis! Porttitor accusamus. Curabitur fusce curabitur.,42.401901245117,-71.119300842285,-1 12 | R_73g1XOnlyONPMmF,Default Response Set,,2016-10-06 14:40:57,2016-10-06 14:40:57,,,,,1,2,5,"Sed cras, commodo pede tempus et, justo. Integer. Orci nibh amet tempor.",Dui id? Metus. Per quam eget dolor dolor magnis ac.,42.401901245117,-71.119300842285,-1 13 | R_0cFjjHecLS767Bz,Default Response Set,,2016-10-06 14:40:57,2016-10-06 14:40:57,,,,,1,2,1,,"Nunc urna tortor, elit. Sapien. Justo vel sapien mi tempor? Dolorem.",42.401901245117,-71.119300842285,-1 14 | -------------------------------------------------------------------------------- /data/Sample Surveys/Comment Coding/Test_Survey_for_Coded_Comments.qsf: -------------------------------------------------------------------------------- 1 | {"SurveyEntry":{"SurveyID":"SV_3POe2UpviI91lxr","SurveyName":"Test Survey for Coded Comments","SurveyDescription":null,"SurveyOwnerID":"UR_8kzO7vEaBPWnAB7","SurveyBrandID":"tufts","DivisionID":null,"SurveyLanguage":"EN","SurveyActiveResponseSet":"RS_4TNA5gm7mkH6MzX","SurveyStatus":"Inactive","SurveyStartDate":"0000-00-00 00:00:00","SurveyExpirationDate":"0000-00-00 00:00:00","SurveyCreationDate":"2016-10-06 12:25:07","CreatorID":"UR_8kzO7vEaBPWnAB7","LastModified":"2016-10-06 12:26:44","LastAccessed":"0000-00-00 00:00:00","LastActivated":"0000-00-00 00:00:00","Deleted":null},"SurveyElements":[{"SurveyID":"SV_3POe2UpviI91lxr","Element":"BL","PrimaryAttribute":"Survey Blocks","SecondaryAttribute":null,"TertiaryAttribute":null,"Payload":[{"Type":"Default","Description":"Default Question Block","ID":"BL_081SVWwpbKE8KFf","BlockElements":[{"Type":"Question","QuestionID":"QID1"},{"Type":"Question","QuestionID":"QID2"}]},{"Type":"Trash","Description":"Trash \/ Unused Questions","ID":"BL_508knOMhdAqYpp3"}]},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"FL","PrimaryAttribute":"Survey Flow","SecondaryAttribute":null,"TertiaryAttribute":null,"Payload":{"Flow":[{"ID":"BL_081SVWwpbKE8KFf","Type":"Block","FlowID":"FL_2"}],"Properties":{"Count":2},"FlowID":"FL_1","Type":"Root"}},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"SO","PrimaryAttribute":"Survey Options","SecondaryAttribute":null,"TertiaryAttribute":null,"Payload":{"BackButton":"false","SaveAndContinue":"true","SurveyProtection":"PublicSurvey","BallotBoxStuffingPrevention":"false","NoIndex":"Yes","SecureResponseFiles":"true","SurveyExpiration":"None","SurveyTermination":"DefaultMessage","Header":"","Footer":"","ProgressBarDisplay":"None","PartialData":"+1 week","ValidationMessage":"","PreviousButton":" << ","NextButton":" >> ","SkinLibrary":"tufts","SkinType":"MQ","Skin":"tufts1","NewScoring":1}},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"SCO","PrimaryAttribute":"Scoring","SecondaryAttribute":null,"TertiaryAttribute":null,"Payload":{"ScoringCategories":[],"ScoringCategoryGroups":[],"ScoringSummaryCategory":null,"ScoringSummaryAfterQuestions":0,"ScoringSummaryAfterSurvey":0,"DefaultScoringCategory":null,"AutoScoringCategory":null}},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"STAT","PrimaryAttribute":"Survey Statistics","SecondaryAttribute":null,"TertiaryAttribute":null,"Payload":{"MobileCompatible":true,"ID":"Survey Statistics"}},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"QC","PrimaryAttribute":"Survey Question Count","SecondaryAttribute":"2","TertiaryAttribute":null,"Payload":null},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"RS","PrimaryAttribute":"RS_4TNA5gm7mkH6MzX","SecondaryAttribute":"Default Response Set","TertiaryAttribute":null,"Payload":null},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"SQ","PrimaryAttribute":"QID1","SecondaryAttribute":"This question has multiple \"other please specify\" options","TertiaryAttribute":null,"Payload":{"QuestionText":"This question has multiple \"other please specify\" options","DataExportTag":"Q1","QuestionType":"MC","Selector":"SAVR","SubSelector":"TX","Configuration":{"QuestionDescriptionOption":"UseText"},"QuestionDescription":"This question has multiple \"other please specify\" options","Choices":{"1":{"Display":"Click to write Choice 1"},"2":{"Display":"Other, please specify:","TextEntry":"true","TextEntrySize":"Medium"},"3":{"Display":"None of the above, explain why:","TextEntry":"true","TextEntrySize":"Medium"}},"ChoiceOrder":["1","2","3"],"Validation":{"Settings":{"ForceResponse":"OFF","ForceResponseType":"ON","Type":"None"}},"RecodeValues":{"1":"1","2":"5","3":"6"},"Language":[],"QuestionID":"QID1"}},{"SurveyID":"SV_3POe2UpviI91lxr","Element":"SQ","PrimaryAttribute":"QID2","SecondaryAttribute":"What's up home skillets? ","TertiaryAttribute":null,"Payload":{"QuestionText":"What's up home skillets? ","DefaultChoices":false,"DataExportTag":"Q2","QuestionType":"TE","Selector":"SL","Configuration":{"QuestionDescriptionOption":"UseText"},"QuestionDescription":"What's up home skillets? ","Validation":{"Settings":{"ForceResponse":"OFF","ForceResponseType":"ON","Type":"None"}},"GradingData":[],"Language":[],"QuestionID":"QID2"}}]} -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q10.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q10.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q10_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q10_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q11.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q11.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q11_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q11_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q12.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q12.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q12_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q12_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q13_family_food.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q13_family_food.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q13_family_food_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q13_family_food_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q14.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q14.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q14_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q14_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q15.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q15.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q15_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q15_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q16.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q16.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q16_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q16_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q2.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q2.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q20.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q20.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q20_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q20_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q21.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q21.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q21_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q21_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q22.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q22.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q22_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q22_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q23.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q23.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q23_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q23_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q24.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q24.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q24_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q24_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q25.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q25.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q25_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q25_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q26.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q26.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q26_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q26_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q27.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q27.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q27_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q27_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q29.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q29.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q29_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q29_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q2_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q2_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q3.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q3.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q31.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q31.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q31_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q31_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q32.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q32.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q32_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q32_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q33.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q33.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q33_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q33_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q34.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q34.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q34_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q34_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q35.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q35.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q35_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q35_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q36.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q36.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q36_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q36_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q37.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q37.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q37_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q37_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q3_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q3_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q5.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q5.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q5_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q5_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q6.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q6.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q6_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q6_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q7.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q7.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q7_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q7_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q8.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q8.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q8_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q8_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q9.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q9.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q9_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/Q9_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/original_first_rows.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/original_first_rows.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q30_cooking_style.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q30_cooking_style.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q30_cooking_style_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q30_cooking_style_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q4_colored_fruit.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q4_colored_fruit.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q4_colored_fruit_results_table.rds: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Long Exhaustive Sample Survey/RDS/q4_colored_fruit_results_table.rds -------------------------------------------------------------------------------- /data/Sample Surveys/Matrix Single Answer Survey/Matrix_Single_Answer_Testing.csv: -------------------------------------------------------------------------------- 1 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Q12_1,Q12_2,Q12_3,Q11_1,Q11_2,Q11_3,Q1_1,Q1_2,Q1_3,Q2_Q2_2,Q2_Q2_4,Q2_Q2_3,Q3_Q2_2,Q3_Q2_4,Q3_Q2_3,Q4_Q2_2,Q4_Q2_4,Q6_1,Q6_2,Q8_1,Q10_Q10_3,LocationLatitude,LocationLongitude,LocationAccuracy 2 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,"In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 2","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 3","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 3","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 2","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 2","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 3","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 2","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 3","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 2","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 3","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 2","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 2","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1","In this survey, we're going to test a variety of different kinds of single answer matrices.  The...-Click to write Statement 1",LocationLatitude,LocationLongitude,LocationAccuracy 3 | {'ImportId': 'responseId'},{'ImportId': 'responseSetId'},{'ImportId': 'ipAddress'},{'ImportId': 'startDate'},{'ImportId': 'endDate'},{'ImportId': 'panel-RecipientLastName'},{'ImportId': 'panel-RecipientFirstName'},{'ImportId': 'panel-RecipientEmail'},{'ImportId': 'panel-ExternalDataReference'},{'ImportId': 'finished'},{'ImportId': 'status'},{'ImportId': 'QID12-1'},{'ImportId': 'QID12-2'},{'ImportId': 'QID12-3'},{'ImportId': 'QID11-1'},{'ImportId': 'QID11-2'},{'ImportId': 'QID11-3'},{'ImportId': 'QID1-1'},{'ImportId': 'QID1-2'},{'ImportId': 'QID1-3'},{'ImportId': 'QID2-1'},{'ImportId': 'QID2-2'},{'ImportId': 'QID2-3'},{'ImportId': 'QID3-1'},{'ImportId': 'QID3-2'},{'ImportId': 'QID3-3'},{'ImportId': 'QID4-1'},{'ImportId': 'QID4-2'},{'ImportId': 'QID6-1'},{'ImportId': 'QID6-2'},{'ImportId': 'QID8-1'},{'ImportId': 'QID10-1'},{'ImportId': 'Location-LocationLatitude'},{'ImportId': 'Location-LocationLongitude'},{'ImportId': 'Location-LocationAccuracy'} 4 | R_9zeKuQluLf9CNU1,Default Response Set,,2017-05-23 14:21:14,2017-05-23 14:21:14,,,,,1,2,1,2,3,1,2,1,3,2,3,3,1,3,3,3,4,2,2,1,2,1,4,42.401901245117,-71.119300842285,-1 5 | R_bHoMX1x6YTkerpH,Default Response Set,,2017-05-23 14:21:14,2017-05-23 14:21:14,,,,,1,2,1,3,1,1,2,3,3,2,4,3,1,1,2,3,2,2,2,2,2,2,3,42.401901245117,-71.119300842285,-1 6 | R_bf1QnzI6BNxlqUl,Default Response Set,,2017-05-23 14:21:14,2017-05-23 14:21:14,,,,,1,2,1,3,1,1,2,3,3,3,4,2,1,1,4,4,2,2,3,1,2,1,4,42.401901245117,-71.119300842285,-1 7 | R_8AP5X5PcEd3itWl,Default Response Set,,2017-05-23 14:21:14,2017-05-23 14:21:14,,,,,1,2,3,2,1,2,2,1,3,4,2,1,2,3,3,4,3,2,2,2,1,3,2,42.401901245117,-71.119300842285,-1 8 | R_6QonGDfxQ79wpJr,Default Response Set,,2017-05-23 14:21:14,2017-05-23 14:21:14,,,,,1,2,2,1,1,2,3,3,2,2,4,2,3,1,4,2,4,3,2,2,2,3,2,42.401901245117,-71.119300842285,-1 9 | -------------------------------------------------------------------------------- /data/Sample Surveys/Multiple Answer Matrix Questions/Insights vs Pre-Insights Headers.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Multiple Answer Matrix Questions/Insights vs Pre-Insights Headers.xlsx -------------------------------------------------------------------------------- /data/Sample Surveys/Multiple Answer Multiple Choices Questions/Insight vs Pre-Insight Headers.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Multiple Answer Multiple Choices Questions/Insight vs Pre-Insight Headers.xlsx -------------------------------------------------------------------------------- /data/Sample Surveys/Multiple Answer Multiple Choices Questions/Multiple_Answer_MC_Questions.csv: -------------------------------------------------------------------------------- 1 | V1,V2,V3,V4,V5,V6,V7,V8,V9,V10,Q2_1,Q2_2,Q2_3,Q4_1,Q4_2,Q4_3,Q3_1,Q3_2,Q3_3,Q3_4,Q3_5,Q5_1,Q5_2,Q5_3,Q5_4,Q5_5,Q5_6,Q5_7,mc_question_five_1,mc_question_five_2,mc_question_five_2_TEXT,mc_question_five_3,LocationLatitude,LocationLongitude,LocationAccuracy, 2 | ResponseID,ResponseSet,Name,ExternalDataReference,EmailAddress,IPAddress,Status,StartDate,EndDate,Finished,Click to write the question text-Click to write Statement 1,Click to write the question text-Click to write Statement 2,Click to write the question text-Click to write Statement 3,Click to write the question text This question has custom RecodeValues-Click to write Statement 1,Click to write the question text This question has custom RecodeValues-Click to write Statement 2,Click to write the question text This question has custom RecodeValues-Click to write Statement 3,"Click to write the question text This question has choice groups, one after the first choice and...-Click to write Statement 1","Click to write the question text This question has choice groups, one after the first choice and...-Click to write Statement 2","Click to write the question text This question has choice groups, one after the first choice and...-Click to write Statement 3","Click to write the question text This question has choice groups, one after the first choice and...-Click to write Choice 2","Click to write the question text This question has choice groups, one after the first choice and...-Click to write Choice 5",Click to write the question text This question has both choice groups and recoded values for the...-Click to write Statement 1,Click to write the question text This question has both choice groups and recoded values for the...-Click to write Statement 2,Click to write the question text This question has both choice groups and recoded values for the...-Click to write Statement 3,Click to write the question text This question has both choice groups and recoded values for the...-Click to write Choice 4,Click to write the question text This question has both choice groups and recoded values for the...-Click to write Choice 5,Click to write the question text This question has both choice groups and recoded values for the...-Click to write Choice 6,Click to write the question text This question has both choice groups and recoded values for the...-Click to write Choice 7,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 1,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 2,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 2-TEXT,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 3,LocationLatitude,LocationLongitude,LocationAccuracy, 3 | R_bIVJQDOvulWU4BL,Default Response Set,Anonymous,,,,2,2016-05-27 11:51:26,2016-05-27 11:51:26,1,,1,1,1,,1,,1,1,1,,1,,,,,1,,,1,Gravida pellentesque consectetuer eleifend risus fusce sit urna diam magnis laoreet.,1,42.401901245117,-71.119300842285,-1, 4 | R_9TRMTVrcxToobFX,Default Response Set,Anonymous,,,,2,2016-05-27 11:51:26,2016-05-27 11:51:26,1,1,1,1,1,,1,,1,1,1,,,1,1,1,,1,1,,1,"Massa rutrum! Magna tempor sodales potenti augue mauris. Praesent viverra? Vitae, dapibus a.",1,42.401901245117,-71.119300842285,-1, 5 | R_0wwjWTTwZZ0Yk5L,Default Response Set,Anonymous,,,,2,2016-05-27 11:51:27,2016-05-27 11:51:27,1,1,1,1,1,1,1,,,1,,1,1,,,,,1,,,1,Montes elementum. Aenean pretium fermentum mauris tincidunt natoque purus duis nulla temporibus? Aliquam. Placerat.,1,42.401901245117,-71.119300842285,-1, 6 | R_6L5kIRYklhmFwEd,Default Response Set,Anonymous,,,,2,2016-05-27 11:51:27,2016-05-27 11:51:27,1,1,1,1,1,,1,,1,1,,1,1,1,1,1,1,1,1,,1,"Non, et tempor. Praesent amet molestie sollicitudin magna integer justo. Lacus. Dolorem eget nec.",1,42.401901245117,-71.119300842285,-1, 7 | R_5d5Farh7brTe56d,Default Response Set,Anonymous,,,,2,2016-05-27 11:51:27,2016-05-27 11:51:27,1,1,,1,1,1,1,,1,1,1,1,1,1,1,,,1,,,1,Urna imperdiet dictumst tincidunt egestas maecenas consectetuer aliquet urna vivamus.,1,42.401901245117,-71.119300842285,-1, 8 | -------------------------------------------------------------------------------- /data/Sample Surveys/Sample Coded Comments/Q5 Coded.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Sample Coded Comments/Q5 Coded.xlsx -------------------------------------------------------------------------------- /data/Sample Surveys/Single Answer Matrix Questions/Insights vs Pre-Insights Headers.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Single Answer Matrix Questions/Insights vs Pre-Insights Headers.xlsx -------------------------------------------------------------------------------- /data/Sample Surveys/Single Answer Matrix Questions/Single_Answer_Matrix_Questions (Insights).csv: -------------------------------------------------------------------------------- 1 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Q2_1,Q2_2,Q2_3,Q4_1,Q4_2,Q4_3,Q3_question_one,Q3_question_two,Q3_question_three,Q5_question_one,Q5_question_two,Q5_question_three,matrix_question_five_question_one,matrix_question_five_question_two,matrix_question_five_question_two_TEXT,matrix_question_five_question_three,LocationLatitude,LocationLongitude,LocationAccuracy 2 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Click to write the question text-Click to write Statement 1,Click to write the question text-Click to write Statement 2,Click to write the question text-Click to write Statement 3,"Click to write the question text This question has variables given for its RecodeValues, aka, Sca...-Click to write Statement 1","Click to write the question text This question has variables given for its RecodeValues, aka, Sca...-Click to write Statement 2","Click to write the question text This question has variables given for its RecodeValues, aka, Sca...-Click to write Statement 3","Click to write the question text This question has variables given for its Question Export Tags,...-Click to write Statement 1","Click to write the question text This question has variables given for its Question Export Tags,...-Click to write Statement 2","Click to write the question text This question has variables given for its Question Export Tags,...-Click to write Statement 3",Click to write the question text This question has variables given for both its Choices and Answe...-Click to write Statement 1,Click to write the question text This question has variables given for both its Choices and Answe...-Click to write Statement 2,Click to write the question text This question has variables given for both its Choices and Answe...-Click to write Statement 3,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 1,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 2,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 2,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 3,LocationLatitude,LocationLongitude,LocationAccuracy 3 | {'ImportId': 'responseId'},{'ImportId': 'responseSetId'},{'ImportId': 'ipAddress'},{'ImportId': 'startDate'},{'ImportId': 'endDate'},{'ImportId': 'panel-RecipientLastName'},{'ImportId': 'panel-RecipientFirstName'},{'ImportId': 'panel-RecipientEmail'},{'ImportId': 'panel-ExternalDataReference'},{'ImportId': 'finished'},{'ImportId': 'status'},{'ImportId': 'QID2-1'},{'ImportId': 'QID2-2'},{'ImportId': 'QID2-3'},{'ImportId': 'QID5-1'},{'ImportId': 'QID5-2'},{'ImportId': 'QID5-3'},{'ImportId': 'QID3-1'},{'ImportId': 'QID3-2'},{'ImportId': 'QID3-3'},{'ImportId': 'QID6-1'},{'ImportId': 'QID6-2'},{'ImportId': 'QID6-3'},{'ImportId': 'QID4-1'},{'ImportId': 'QID4-2'},{'ImportId': 'QID4-2-TEXT'},{'ImportId': 'QID4-3'},{'ImportId': 'Location-LocationLatitude'},{'ImportId': 'Location-LocationLongitude'},{'ImportId': 'Location-LocationAccuracy'} 4 | R_9H2nlL82R9Yq21v,Default Response Set,,2016-05-27 11:33:34,2016-05-27 11:33:34,,,,,1,2,3,4,4,12,10,11,1,1,4,10,11,12,13,10,Massa. Mi nec facilisis culpa orci wisi vehicula montes? Fermentum.,12,42.401901245117,-71.119300842285,-1 5 | R_4MlalJojzHA3Uzj,Default Response Set,,2016-05-27 11:33:34,2016-05-27 11:33:34,,,,,1,2,4,4,3,12,11,13,1,4,1,10,12,13,13,10,"Accumsan lorem, in accusamus morbi accumsan scelerisque mauris quam sagittis interdum. Orci! Cursus vel.",10,42.401901245117,-71.119300842285,-1 6 | R_89cYYn2ZcBOxIbz,Default Response Set,,2016-05-27 11:33:34,2016-05-27 11:33:34,,,,,1,2,2,3,1,12,11,13,2,2,3,13,10,12,11,13,Bibendum in. Vel dapibus etiam facilisis primis? Malesuada rutrum ante lacus luctus at.,10,42.401901245117,-71.119300842285,-1 7 | R_2m09jW7L4aqipYV,Default Response Set,,2016-05-27 11:33:34,2016-05-27 11:33:34,,,,,1,2,4,2,2,10,11,13,3,4,1,13,12,12,12,12,Augue. Eget primis sed. Commodo bibendum? Nulla metus? Justo tortor.,10,42.401901245117,-71.119300842285,-1 8 | R_0wUVL7ttMUcpJOJ,Default Response Set,,2016-05-27 11:33:34,2016-05-27 11:33:35,,,,,1,2,3,3,1,11,13,12,4,4,4,12,13,13,13,11,Fringilla vivamus pede? Nunc augue ultricies mauris nulla pharetra. Cursus ultricies tortor luctus ridiculus praesent.,10,42.401901245117,-71.119300842285,-1 9 | -------------------------------------------------------------------------------- /data/Sample Surveys/Single Answer Matrix Questions/Single_Answer_Matrix_Questions.csv: -------------------------------------------------------------------------------- 1 | V1,V2,V3,V4,V5,V6,V7,V8,V9,V10,Q2_1,Q2_2,Q2_3,Q4_1,Q4_2,Q4_3,question_one,question_two,question_three,question_one,question_two,question_three,question_one,question_two,matrix_question_fivequestion_two_TEXT,question_three,LocationLatitude,LocationLongitude,LocationAccuracy, 2 | ResponseID,ResponseSet,Name,ExternalDataReference,EmailAddress,IPAddress,Status,StartDate,EndDate,Finished,Click to write the question text-Click to write Statement 1,Click to write the question text-Click to write Statement 2,Click to write the question text-Click to write Statement 3,"Click to write the question text This question has variables given for its RecodeValues, aka, Sca...-Click to write Statement 1","Click to write the question text This question has variables given for its RecodeValues, aka, Sca...-Click to write Statement 2","Click to write the question text This question has variables given for its RecodeValues, aka, Sca...-Click to write Statement 3","Click to write the question text This question has variables given for its Question Export Tags,...-Click to write Statement 1","Click to write the question text This question has variables given for its Question Export Tags,...-Click to write Statement 2","Click to write the question text This question has variables given for its Question Export Tags,...-Click to write Statement 3",Click to write the question text This question has variables given for both its Choices and Answe...-Click to write Statement 1,Click to write the question text This question has variables given for both its Choices and Answe...-Click to write Statement 2,Click to write the question text This question has variables given for both its Choices and Answe...-Click to write Statement 3,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 1,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 2,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 2-TEXT,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-Click to write Statement 3,LocationLatitude,LocationLongitude,LocationAccuracy, 3 | R_9H2nlL82R9Yq21v,Default Response Set,Anonymous,,,,2,2016-05-27 11:33:34,2016-05-27 11:33:34,1,3,4,4,12,10,11,1,1,4,10,11,12,13,10,Massa. Mi nec facilisis culpa orci wisi vehicula montes? Fermentum.,12,42.401901245117,-71.119300842285,-1, 4 | R_4MlalJojzHA3Uzj,Default Response Set,Anonymous,,,,2,2016-05-27 11:33:34,2016-05-27 11:33:34,1,4,4,3,12,11,13,1,4,1,10,12,13,13,10,"Accumsan lorem, in accusamus morbi accumsan scelerisque mauris quam sagittis interdum. Orci! Cursus vel.",10,42.401901245117,-71.119300842285,-1, 5 | R_89cYYn2ZcBOxIbz,Default Response Set,Anonymous,,,,2,2016-05-27 11:33:34,2016-05-27 11:33:34,1,2,3,1,12,11,13,2,2,3,13,10,12,11,13,Bibendum in. Vel dapibus etiam facilisis primis? Malesuada rutrum ante lacus luctus at.,10,42.401901245117,-71.119300842285,-1, 6 | R_2m09jW7L4aqipYV,Default Response Set,Anonymous,,,,2,2016-05-27 11:33:34,2016-05-27 11:33:34,1,4,2,2,10,11,13,3,4,1,13,12,12,12,12,Augue. Eget primis sed. Commodo bibendum? Nulla metus? Justo tortor.,10,42.401901245117,-71.119300842285,-1, 7 | R_0wUVL7ttMUcpJOJ,Default Response Set,Anonymous,,,,2,2016-05-27 11:33:34,2016-05-27 11:33:35,1,3,3,1,11,13,12,4,4,4,12,13,13,13,11,Fringilla vivamus pede? Nunc augue ultricies mauris nulla pharetra. Cursus ultricies tortor luctus ridiculus praesent.,10,42.401901245117,-71.119300842285,-1, 8 | -------------------------------------------------------------------------------- /data/Sample Surveys/Single Answer Multiple Choice Questions/Insights vs Pre-Insights Headers.xlsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Single Answer Multiple Choice Questions/Insights vs Pre-Insights Headers.xlsx -------------------------------------------------------------------------------- /data/Sample Surveys/Single Answer Multiple Choice Questions/Single_Answer_MC_Questions (Insights).csv: -------------------------------------------------------------------------------- 1 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Q2,Q4,Q3,Q5,mc_question_five,mc_question_five_TEXT,LocationLatitude,LocationLongitude,LocationAccuracy 2 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Click to write the question text,Click to write the question text This question has custom RecodeValues,"Click to write the question text This question has choice groups, one after the first choice and...",Click to write the question text This question has both choice groups and recoded values for the...,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...,LocationLatitude,LocationLongitude,LocationAccuracy 3 | {'ImportId': 'responseId'},{'ImportId': 'responseSetId'},{'ImportId': 'ipAddress'},{'ImportId': 'startDate'},{'ImportId': 'endDate'},{'ImportId': 'panel-RecipientLastName'},{'ImportId': 'panel-RecipientFirstName'},{'ImportId': 'panel-RecipientEmail'},{'ImportId': 'panel-ExternalDataReference'},{'ImportId': 'finished'},{'ImportId': 'status'},{'ImportId': 'QID2'},{'ImportId': 'QID5'},{'ImportId': 'QID3'},{'ImportId': 'QID6'},{'ImportId': 'QID4'},{'ImportId': 'QID4-TEXT'},{'ImportId': 'Location-LocationLatitude'},{'ImportId': 'Location-LocationLongitude'},{'ImportId': 'Location-LocationAccuracy'} 4 | R_862TbryT6hpIAfP,Default Response Set,,2016-05-27 11:44:08,2016-05-27 11:44:08,,,,,1,2,3,12,4,13,2,Dictumst mattis ultricies sem? Ligula morbi rhoncus tincidunt iaculis elementum suscipit.,42.401901245117,-71.119300842285,-1 5 | R_5juoQy4AOxpQtb7,Default Response Set,,2016-05-27 11:44:08,2016-05-27 11:44:08,,,,,1,2,3,12,5,13,3,,42.401901245117,-71.119300842285,-1 6 | R_8tXIB6RuuzgLxKB,Default Response Set,,2016-05-27 11:44:08,2016-05-27 11:44:08,,,,,1,2,3,11,1,11,3,,42.401901245117,-71.119300842285,-1 7 | R_3R9QbYSBDuBxhe5,Default Response Set,,2016-05-27 11:44:08,2016-05-27 11:44:08,,,,,1,2,2,12,5,16,3,,42.401901245117,-71.119300842285,-1 8 | R_eWmiNLb28AJYLyd,Default Response Set,,2016-05-27 11:44:08,2016-05-27 11:44:08,,,,,1,2,3,10,3,10,2,In elit aliquam convallis sem commodo auctor commodo porttitor ac.,42.401901245117,-71.119300842285,-1 9 | -------------------------------------------------------------------------------- /data/Sample Surveys/Single Answer Multiple Choice Questions/Single_Answer_MC_Questions.csv: -------------------------------------------------------------------------------- 1 | V1,V2,V3,V4,V5,V6,V7,V8,V9,V10,Q2,Q4,Q3,Q5,mc_question_five,mc_question_five_TEXT,LocationLatitude,LocationLongitude,LocationAccuracy, 2 | ResponseID,ResponseSet,Name,ExternalDataReference,EmailAddress,IPAddress,Status,StartDate,EndDate,Finished,Click to write the question text,Click to write the question text This question has custom RecodeValues,"Click to write the question text This question has choice groups, one after the first choice and...",Click to write the question text This question has both choice groups and recoded values for the...,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...,This is a multiple answer likert matrix question with text entry and survey logic in two respecti...-TEXT,LocationLatitude,LocationLongitude,LocationAccuracy, 3 | R_862TbryT6hpIAfP,Default Response Set,Anonymous,,,,2,2016-05-27 11:44:08,2016-05-27 11:44:08,1,3,12,4,13,2,Dictumst mattis ultricies sem? Ligula morbi rhoncus tincidunt iaculis elementum suscipit.,42.401901245117,-71.119300842285,-1, 4 | R_5juoQy4AOxpQtb7,Default Response Set,Anonymous,,,,2,2016-05-27 11:44:08,2016-05-27 11:44:08,1,3,12,5,13,3,,42.401901245117,-71.119300842285,-1, 5 | R_8tXIB6RuuzgLxKB,Default Response Set,Anonymous,,,,2,2016-05-27 11:44:08,2016-05-27 11:44:08,1,3,11,1,11,3,,42.401901245117,-71.119300842285,-1, 6 | R_3R9QbYSBDuBxhe5,Default Response Set,Anonymous,,,,2,2016-05-27 11:44:08,2016-05-27 11:44:08,1,2,12,5,16,3,,42.401901245117,-71.119300842285,-1, 7 | R_eWmiNLb28AJYLyd,Default Response Set,Anonymous,,,,2,2016-05-27 11:44:08,2016-05-27 11:44:08,1,3,10,3,10,2,In elit aliquam convallis sem commodo auctor commodo porttitor ac.,42.401901245117,-71.119300842285,-1, 8 | -------------------------------------------------------------------------------- /data/Sample Surveys/Survey Logic/Survey_Logic_EVERYWHERE.csv: -------------------------------------------------------------------------------- 1 | V1,V2,V3,V4,V5,V6,V7,V8,V9,V10,Q1,Q2,Q3,Q4,Q5_1,Q5_2,Q5_3,LocationLatitude,LocationLongitude,LocationAccuracy, 2 | ResponseID,ResponseSet,Name,ExternalDataReference,EmailAddress,IPAddress,Status,StartDate,EndDate,Finished,Yo have a question,Click to write the question text,Click to write the question text,Click to write the question text,Click to write the question text-Click to write Statement 1,Click to write the question text-Click to write Statement 2,Click to write the question text-Click to write Statement 3,LocationLatitude,LocationLongitude,LocationAccuracy, 3 | R_6Yeyq8yNFUHQwK1,Default Response Set,Anonymous,,,,2,2016-06-08 11:26:06,2016-06-08 11:26:06,1,3,2,2,1,,,,42.401901245117,-71.119300842285,-1, 4 | R_0PxRPQhcH4qUbtz,Default Response Set,Anonymous,,,,2,2016-06-08 11:26:06,2016-06-08 11:26:06,1,1,2,2,1,,,,42.401901245117,-71.119300842285,-1, 5 | R_8Jut1nMbg63kgVn,Default Response Set,Anonymous,,,,2,2016-06-08 11:26:06,2016-06-08 11:26:06,1,2,2,2,2,,,,42.401901245117,-71.119300842285,-1, 6 | R_54I2czVrkQBvPSZ,Default Response Set,Anonymous,,,,2,2016-06-08 11:26:06,2016-06-08 11:26:06,1,1,2,1,1,,,,42.401901245117,-71.119300842285,-1, 7 | R_bqGVsdWs2NBTnpj,Default Response Set,Anonymous,,,,2,2016-06-08 11:26:07,2016-06-08 11:26:07,1,3,2,1,2,,,,42.401901245117,-71.119300842285,-1, 8 | R_4JHt4mLklkkCMZv,Default Response Set,Anonymous,,,,2,2016-06-08 14:45:42,2016-06-08 14:45:42,1,1,1,2,,,,,42.401901245117,-71.119300842285,-1, 9 | R_9NzIhEg9T2SnLtb,Default Response Set,Anonymous,,,,2,2016-06-08 14:45:42,2016-06-08 14:45:42,1,3,1,2,,,,,42.401901245117,-71.119300842285,-1, 10 | R_3t6cn60CTyOhVD7,Default Response Set,Anonymous,,,,2,2016-06-08 14:45:42,2016-06-08 14:45:42,1,2,1,3,2,3,,3,42.401901245117,-71.119300842285,-1, 11 | R_38bTfUjT5ehinHL,Default Response Set,Anonymous,,,,2,2016-06-08 14:45:42,2016-06-08 14:45:42,1,2,2,2,,,,,42.401901245117,-71.119300842285,-1, 12 | R_efzuCpBhJtJND5X,Default Response Set,Anonymous,,,,2,2016-06-08 14:45:42,2016-06-08 14:45:42,1,1,2,2,,,,,42.401901245117,-71.119300842285,-1, 13 | -------------------------------------------------------------------------------- /data/Sample Surveys/Survey Logic/Survey_Logic_EVERYWHERE.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Survey Logic/Survey_Logic_EVERYWHERE.docx -------------------------------------------------------------------------------- /data/Sample Surveys/Survey Logic/results_tables.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/Sample Surveys/Survey Logic/results_tables.docx -------------------------------------------------------------------------------- /data/Sample Surveys/Test Getting Choice Text from Response Columns/Choice_Text_from_Response_Columns.csv: -------------------------------------------------------------------------------- 1 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Q1_1,Q1_2,Q1_3,Q1_4,are-dashes-in-dexps_1,are-dashes-in-dexps_2,are-dashes-in-dexps_3,are-dashes-in-dexps_4,Q3_1,Q3_2,Q3_3,Q3_4,Q4_1,Q4_2,Q4_3,Q4_4,LocationLatitude,LocationLongitude,LocationAccuracy 2 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,This question has no dashes-Click to write Statement 1,This question has no dashes-Click to write Statement 2,This question has no dashes-Click to write Statement 3,This question has no dashes-Click to write Statement 4,This question has no dashes-Click to write Statement 1,This question has no dashes-Click to write Statement 2,This question has no dashes-Click to write Statement 3,This question has no dashes-Click to write Statement 4,This question has one-dash-Click to write Statement 1,This question has one-dash-Click to write Statement 2,This question has one-dash-Click to write Statement 3,This question has one-dash-Click to write Statement 4,this is an-html table as a question please-dear-god-no please - never use this this is -- unnecss...-Click to write Statement 1,this is an-html table as a question please-dear-god-no please - never use this this is -- unnecss...-Click to write Statement 2,this is an-html table as a question please-dear-god-no please - never use this this is -- unnecss...-Click to write Statement 3,this is an-html table as a question please-dear-god-no please - never use this this is -- unnecss...-Click to write Statement 4,LocationLatitude,LocationLongitude,LocationAccuracy 3 | {'ImportId': 'responseId'},{'ImportId': 'responseSetId'},{'ImportId': 'ipAddress'},{'ImportId': 'startDate'},{'ImportId': 'endDate'},{'ImportId': 'panel-RecipientLastName'},{'ImportId': 'panel-RecipientFirstName'},{'ImportId': 'panel-RecipientEmail'},{'ImportId': 'panel-ExternalDataReference'},{'ImportId': 'finished'},{'ImportId': 'status'},{'ImportId': 'QID1-1'},{'ImportId': 'QID1-2'},{'ImportId': 'QID1-3'},{'ImportId': 'QID1-4'},{'ImportId': 'QID5-1'},{'ImportId': 'QID5-2'},{'ImportId': 'QID5-3'},{'ImportId': 'QID5-4'},{'ImportId': 'QID3-1'},{'ImportId': 'QID3-2'},{'ImportId': 'QID3-3'},{'ImportId': 'QID3-4'},{'ImportId': 'QID4-1'},{'ImportId': 'QID4-2'},{'ImportId': 'QID4-3'},{'ImportId': 'QID4-4'},{'ImportId': 'Location-LocationLatitude'},{'ImportId': 'Location-LocationLongitude'},{'ImportId': 'Location-LocationAccuracy'} 4 | R_0PshI3QxglaoaTX,Default Response Set,,2016-06-15 17:34:00,2016-06-15 17:34:00,,,,,1,2,3,2,2,2,4,5,2,3,2,5,4,7,6,2,4,6,42.401901245117,-71.119300842285,-1 5 | R_7PZxT7ec15lgeEt,Default Response Set,,2016-06-15 17:34:00,2016-06-15 17:34:00,,,,,1,2,1,2,2,1,3,7,6,6,7,3,2,1,7,2,2,4,42.401901245117,-71.119300842285,-1 6 | R_6xjIWNIfAb5nm5L,Default Response Set,,2016-06-15 17:34:00,2016-06-15 17:34:00,,,,,1,2,1,1,2,5,3,7,3,1,1,3,2,4,3,2,5,5,42.401901245117,-71.119300842285,-1 7 | R_cUtkTpSAOdvhhVr,Default Response Set,,2016-06-15 17:34:00,2016-06-15 17:34:00,,,,,1,2,2,6,5,6,2,5,6,6,1,2,1,7,7,3,4,1,42.401901245117,-71.119300842285,-1 8 | R_6X6aNnAYzPa8imp,Default Response Set,,2016-06-15 17:34:00,2016-06-15 17:34:00,,,,,1,2,5,5,6,7,6,7,5,7,1,6,1,4,2,3,7,5,42.401901245117,-71.119300842285,-1 9 | -------------------------------------------------------------------------------- /data/Sample Surveys/User Notes Survey/Notes_Survey.csv: -------------------------------------------------------------------------------- 1 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Q1,Q2,Q3,LocationLatitude,LocationLongitude,LocationAccuracy 2 | ResponseID,ResponseSet,IPAddress,StartDate,EndDate,RecipientLastName,RecipientFirstName,RecipientEmail,ExternalDataReference,Finished,Status,Click to write the question text,Click to write the question text,Click to write the question text,LocationLatitude,LocationLongitude,LocationAccuracy 3 | {'ImportId': 'responseId'},{'ImportId': 'responseSetId'},{'ImportId': 'ipAddress'},{'ImportId': 'startDate'},{'ImportId': 'endDate'},{'ImportId': 'panel-RecipientLastName'},{'ImportId': 'panel-RecipientFirstName'},{'ImportId': 'panel-RecipientEmail'},{'ImportId': 'panel-ExternalDataReference'},{'ImportId': 'finished'},{'ImportId': 'status'},{'ImportId': 'QID1'},{'ImportId': 'QID2'},{'ImportId': 'QID3'},{'ImportId': 'Location-LocationLatitude'},{'ImportId': 'Location-LocationLongitude'},{'ImportId': 'Location-LocationAccuracy'} 4 | R_5gmKcYWZYLfS4LP,Default Response Set,,2017-02-10 10:54:41,2017-02-10 10:54:41,,,,,1,2,2,2,2,42.401901245117,-71.119300842285,-1 5 | R_d69Hn3x0hcwIjo9,Default Response Set,,2017-02-10 10:54:41,2017-02-10 10:54:41,,,,,1,2,2,2,1,42.401901245117,-71.119300842285,-1 6 | R_1Y6oxyO1DKCtpOd,Default Response Set,,2017-02-10 10:54:41,2017-02-10 10:54:41,,,,,1,2,1,3,1,42.401901245117,-71.119300842285,-1 7 | R_6SyS0dQ6dJLzDil,Default Response Set,,2017-02-10 10:54:41,2017-02-10 10:54:41,,,,,1,2,2,1,2,42.401901245117,-71.119300842285,-1 8 | R_ekONO1l72MyUjEF,Default Response Set,,2017-02-10 10:54:42,2017-02-10 10:54:42,,,,,1,2,2,2,1,42.401901245117,-71.119300842285,-1 9 | -------------------------------------------------------------------------------- /data/sample_original_first_rows.rda: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/sample_original_first_rows.rda -------------------------------------------------------------------------------- /data/sample_responses.rda: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/sample_responses.rda -------------------------------------------------------------------------------- /data/sample_survey.rda: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/data/sample_survey.rda -------------------------------------------------------------------------------- /inst/shiny/www/custom.css: -------------------------------------------------------------------------------- 1 | /* Table Formatting: 2 | * - The question descriptions and display logic tables 3 | * should have a bolded first entry (the data export tag) 4 | * - Bold the 3rd to last rows of question descriptions, for 5 | * a 'header' effect 6 | * - Center the 'header' of the text appendices */ 7 | .question_description tr:first-child td { 8 | font-weight: bold; 9 | } 10 | .survey_logic tr:first-child td { 11 | font-weight: bold; 12 | } 13 | .question_description tr:nth-child(n+3) { 14 | font-weight: bold; 15 | } 16 | .text_appendices tr:nth-child(-n+4) { 17 | text-align: center; 18 | } 19 | 20 | 21 | /* Sidebar Styling: 22 | * - uniform padding for buttons and the menu. 23 | * - the 'Insights?' button has text associated with it 24 | * that is getting styled to match proper margins. 25 | * - the "Stop App" button has particular styling to keep 26 | * it at the bottom of the page */ 27 | ul.treeview-menu.menu-open { 28 | padding-bottom: 10px; 29 | } 30 | .sidebar-menu a.btn { 31 | margin-left: 20px; 32 | } 33 | .sidebar-text { 34 | white-space:normal!important; 35 | padding-left:12px; 36 | padding-right:12px; 37 | } 38 | #quit { 39 | position:fixed; 40 | bottom:0; 41 | left:0; 42 | margin-left: 20px; 43 | margin-bottom: 10px; 44 | } 45 | 46 | /* fixing the navbar, logo, and sidebar 47 | */ 48 | .content { 49 | padding-top: 60px; 50 | } 51 | .main-sidebar { 52 | position: fixed; 53 | } 54 | -------------------------------------------------------------------------------- /inst/shiny/www/custom.js: -------------------------------------------------------------------------------- 1 | // This Javascript file makes heavy use of j-query to select elements of the page 2 | // and apply changes to all selected elements. Javascript is primarily for dynamically updating 3 | // the contents of a web-page. In the #submit button code later, I make use of the fact that 4 | // both JavaScript and Shiny are reacting to updates to user input and since it was easier to make 5 | // the submit button send the data through javascript than to get Shiny to do this I had the 6 | // Javascript compute the data export tags associated to the selected and unselected boxes in the 7 | // include/exclude questions page and send them to Shiny through the javascript method Shiny.onInputChange 8 | 9 | // The StackOverflow documentation on the Shiny Javascript-API is the best, I think: 10 | // https://stackoverflow.com/documentation/shiny/3149/javascript-api/19807/sending-data-from-client-to-server#t=201706261946375739113 11 | // I haven't been able to find other good documentation, even from Shiny. 12 | 13 | // jQuery is a very powerful library, read more about how to use it at https://jquery.com/ 14 | // Everywhere you see a $(...) in this document, it is jQuery. 15 | 16 | 17 | 18 | // Make the sidebar opens automatically 19 | $("document").ready(function() { 20 | setTimeout(function() { 21 | $("body").toggleClass('sidebar-collapse', false); 22 | $("li.treeview").children("a").first().click(); 23 | }, 5); 24 | }); 25 | 26 | // Make the select-all/unselect-all button select all the checkboxes 27 | // on the page if not all of them are already checked, and to uncheck 28 | // all of them if they are all already checked. 29 | $("document").ready(function() { 30 | $('#selectAll').click(function(e){ 31 | var table= $("#select_qdict").find(".dataTables_wrapper"); 32 | if ($('td input:checkbox:checked',table).length == $('td input:checkbox',table).length) { 33 | $('td input:checkbox',table).removeAttr("checked"); 34 | } else { 35 | $('td input:checkbox',table).prop('checked', true); 36 | } 37 | }); 38 | }); 39 | 40 | // Bold things on the display logic page, so that they are more readable 41 | $("document").ready(function() { 42 | setInterval(function() { 43 | if ($('li:contains("display logic")').attr("class") == "active") { 44 | selection = $('td:contains("Choice Display Logic:")'); 45 | selection = selection.add($('td:contains("Question Display Logic:")')); 46 | selection = selection.add($('td:contains("Skip Logic:")')); 47 | selection = selection.add($('td:contains("Display Logic for:")')); 48 | selection = selection.add($('td:contains("Answer Display Logic:")')); 49 | selection.each(function(index) { this.style.fontWeight = 'bold'; }); 50 | } 51 | }, 100); 52 | }); 53 | 54 | // Send the lists of the selected and unselected questions to Shiny when the #submit button is clicked 55 | // through the Shiny.onInputChange method. 56 | $('document').ready(function() { 57 | $('#submit').click(function(e) { 58 | var unselected_output = []; 59 | var unselected = $('td input:checkbox:not(:checked)').parent().siblings(':nth-child(2)').map(function() { 60 | return($(this).text()); 61 | }); 62 | for (var i=0; iAA)} 6 | \usage{ 7 | appendix_lettering(number, base = 26, suffix = "") 8 | } 9 | \arguments{ 10 | \item{number}{is a positive integer to be converted into 11 | an alphabetic index.} 12 | 13 | \item{base}{is a positive integer used to specify the size of the 14 | alphabet used for alphabetic indexing.} 15 | 16 | \item{suffix}{is appended to the output of the function, and is used 17 | in the functions recursive steps to include the letters already computed 18 | in previous steps.} 19 | } 20 | \description{ 21 | This function works recursively, at each step calculating each 22 | place value of the given number in base 26. The suffix is used 23 | to save the letters from the previous steps, and the base is 24 | automatically assumed to be 26 for use with the English alphabet. 25 | } 26 | \examples{ 27 | appendix_lettering(1000) 28 | [1] "ALL" 29 | sapply(1:60, appendix_lettering) 30 | [1] "A" "B" "C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N" 31 | [15] "O" "P" "Q" "R" "S" "T" "U" "V" "W" "X" "Y" "Z" "AA" "AB" 32 | [29] "AC" "AD" "AE" "AF" "AG" "AH" "AI" "AJ" "AK" "AL" "AM" "AN" "AO" "AP" 33 | [43] "AQ" "AR" "AS" "AT" "AU" "AV" "AW" "AX" "AY" "AZ" "BA" "BB" "BC" "BD" 34 | [57] "BE" "BF" "BG" "BH" 35 | } 36 | -------------------------------------------------------------------------------- /man/ask_for_csv.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/loading_files.R 3 | \name{ask_for_csv} 4 | \alias{ask_for_csv} 5 | \title{Ask the user for the Qualtrics Response Set} 6 | \usage{ 7 | ask_for_csv(responsesfile, headerrows) 8 | } 9 | \arguments{ 10 | \item{responsesfile}{this is the file path of a CSV response set to a Qualtrics survey} 11 | 12 | \item{headerrows}{the number of rows before responses begin in the CSV data} 13 | } 14 | \value{ 15 | a list of two elements: the responses data frame, and the original_first_rows data frame 16 | } 17 | \description{ 18 | ask_for_csv() inputs a file and a number of headerrows and returns a 19 | list containing a responses data frame, and a 1-2 row data frame of the 20 | responses' headers. Both input parameters are optional in the sense that 21 | they do not have to be provided inline to the function, and that the 22 | function will ask the user to choose a file for the responsesfile if one is 23 | not provided inline, and it will default to using 3 headerrows. 24 | } 25 | -------------------------------------------------------------------------------- /man/ask_for_qsf.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/loading_files.R 3 | \name{ask_for_qsf} 4 | \alias{ask_for_qsf} 5 | \title{Ask the user for the Qualtrics Survey file} 6 | \usage{ 7 | ask_for_qsf(surveyfile) 8 | } 9 | \arguments{ 10 | \item{surveyfile}{The file path to a Qualtrics survey file} 11 | } 12 | \value{ 13 | The survey file the user uploads, as a list 14 | } 15 | \description{ 16 | This function can be provided the path to a 17 | Qualtrics survey as its parameter, or 18 | the function will prompt the user to specify 19 | the path to the file. 20 | } 21 | -------------------------------------------------------------------------------- /man/blocks_from_survey.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{blocks_from_survey} 4 | \alias{blocks_from_survey} 5 | \title{Generate a List of Survey Blocks} 6 | \usage{ 7 | blocks_from_survey(survey) 8 | } 9 | \arguments{ 10 | \item{survey}{A qualtrics survey list object, 11 | uploaded from a Qualtrics Survey File (QSF). Use 12 | ask_for_qsf() to create such a survey list object from a QSF file.} 13 | } 14 | \value{ 15 | The blocks element returned is a list of blocks containing for 16 | each a type, description, ID, and BlockElements (which contains the 17 | list of questions included in a given block). 18 | } 19 | \description{ 20 | This function takes the survey blocks out of the survey 21 | and turns them into their own list for later use. 22 | Additionally, the block element can be further reduced to include 23 | only the payload of the survey blocks. 24 | } 25 | -------------------------------------------------------------------------------- /man/blocks_header_to_html.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{blocks_header_to_html} 4 | \alias{blocks_header_to_html} 5 | \title{Block's Header to HTML} 6 | \usage{ 7 | blocks_header_to_html(blocks) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of blocks with a 'header' inserted by either the 11 | get_reorganized_questions_and_blocks or split_respondents functions.} 12 | } 13 | \value{ 14 | An HTML string that can be added as a section header in survey reports. 15 | } 16 | \description{ 17 | Get an HTML Header for a list of survey blocks. The header 18 | is created by either get_reorganized_questions_and_blocks or 19 | by split_respondents. 20 | } 21 | -------------------------------------------------------------------------------- /man/choice_text_from_question.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{choice_text_from_question} 4 | \alias{choice_text_from_question} 5 | \title{Get the Choice Text based on the Choice from a Question} 6 | \usage{ 7 | choice_text_from_question(question, choice) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. The question must have a paired 12 | response column placed into the question 13 | under [['Responses']]. The insertion of the responses into questions is 14 | handled by link_responses_to_questions.} 15 | 16 | \item{choice}{A numeric value representing the choice made in a response 17 | to the question provided. This choice can be a choice in a cell in the 18 | response columns associated with the given question, but it can also be a 19 | choice which was not chosen by any respondents in the responses dataframe 20 | as long as it is a choice built into the question's construction.} 21 | } 22 | \description{ 23 | Input a question and a variable corresponding to a choice, 24 | and this function returns the choice text. The function 25 | works by determining the question type and some question properties 26 | and then using a combination of the question's list of choices 27 | and related values. The text is then cleaned of any HTML before 28 | returned. 29 | } 30 | -------------------------------------------------------------------------------- /man/choice_text_from_response_column.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{choice_text_from_response_column} 4 | \alias{choice_text_from_response_column} 5 | \title{Get the Choice Text from the First Row of the Responses} 6 | \usage{ 7 | choice_text_from_response_column(response_column, original_first_row, blocks) 8 | } 9 | \arguments{ 10 | \item{response_column}{The string name of a response column from the response set.} 11 | 12 | \item{original_first_row}{A dataframe contianing the header information 13 | for each column of response data. This dataframe should include a row for the DataExportTag based 14 | response column names, another for the Question Text stem and choice text (although 15 | truncated), and a row with QID based column names.} 16 | 17 | \item{blocks}{A list of the survey's blocks, with the questions included in them} 18 | } 19 | \value{ 20 | The choice text corresponding to a response column 21 | } 22 | \description{ 23 | This function uses the first row of the response data from Qualtrics 24 | to determine the choice text a response column corresponds to. 25 | } 26 | -------------------------------------------------------------------------------- /man/clean_html.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{clean_html} 4 | \alias{clean_html} 5 | \title{Clean HTML and whitespace from a string} 6 | \usage{ 7 | clean_html(text) 8 | } 9 | \arguments{ 10 | \item{text}{any text string that might contain HTML or whitespace that needs stripped.} 11 | } 12 | \value{ 13 | text without any html or extraneous whitespace. 14 | } 15 | \description{ 16 | This function uses regex extensively to clean HTML out of a given text block. 17 | "(&[a-z]*;|<.*?>)" is the first regular expression used. 18 | It matches a substring that starts with & and ends with ; with 19 | lower case letters between them, or a substring with < and > on each side, with 20 | any characters between. Each matched substring is replaced with a space character. 21 | The next regex is "\\s+". It matches multiple characters of whitespace, and 22 | reduces them to a single space character. 23 | The last regex used is "^\\s+|\\s+$". It matches whitespace at the beginning 24 | or end of the text and removes it. 25 | } 26 | -------------------------------------------------------------------------------- /man/clean_question_text.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{clean_question_text} 4 | \alias{clean_question_text} 5 | \title{Create Cleaned Question Text} 6 | \usage{ 7 | clean_question_text(questions) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions extracted from a Qualtrics QSF file. Use 11 | questions_from_survey() to get them from an imported survey.} 12 | } 13 | \value{ 14 | A list of questions which now include in their Payload a QuestionTextClean 15 | element, a copy of the QuestionText but cleaned of any HTML tags and HTML entities. 16 | } 17 | \description{ 18 | This function loops through every question and applies the clean_html function to 19 | the QuestionText and then saves the cleaned output to QuestionTextClean. 20 | } 21 | -------------------------------------------------------------------------------- /man/create_html_results_tables.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{create_html_results_tables} 4 | \alias{create_html_results_tables} 5 | \title{Create a List of HTML Versions of the Results Tables} 6 | \usage{ 7 | create_html_results_tables(blocks, flow, include_block_headers = TRUE) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of the survey blocks, with the questions included in them.} 11 | 12 | \item{flow}{A list of strings identifying the blocks in the order that they appear 13 | within the survey.} 14 | 15 | \item{include_block_headers}{A boolean (default: TRUE) parameter to indicate 16 | whether or not there should be
html headers inserted before each block with the 17 | block's description.} 18 | } 19 | \value{ 20 | A list of HTML results tables for each question 21 | } 22 | \description{ 23 | Create a List of HTML Versions of the Results Tables 24 | } 25 | -------------------------------------------------------------------------------- /man/create_merged_response_column.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{create_merged_response_column} 4 | \alias{create_merged_response_column} 5 | \title{Add a Custom Response Column with Merged Contents} 6 | \usage{ 7 | create_merged_response_column(response_columns, col_name, question_blocks, 8 | survey_responses) 9 | } 10 | \arguments{ 11 | \item{response_columns}{a list of names of response columns} 12 | 13 | \item{col_name}{the desired name for the added output column} 14 | 15 | \item{question_blocks}{a list of blocks with questions inserted 16 | in place of the BlockElements.} 17 | 18 | \item{survey_responses}{the data frame of responses as imported by 19 | ask_for_csv()} 20 | } 21 | \value{ 22 | a response data frame with a single new column which 23 | represents the contents of the specified response_columns. 24 | } 25 | \description{ 26 | The create_merged_response_column() function allows a user to 27 | create a response set with a column reflecting the combined 28 | contents of several different columns. If the user specifies 29 | response columns that are part of the survey question responses, 30 | then the responses are coded and the coded values are used 31 | instead of the variable response values. The column is appended to 32 | the response set and the response set with the additional 33 | new column is returned to the user. 34 | } 35 | -------------------------------------------------------------------------------- /man/create_panel_data.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{create_panel_data} 4 | \alias{create_panel_data} 5 | \title{Create Panel Data for Reshaped Data} 6 | \usage{ 7 | create_panel_data(panel_columns, survey_responses, lean_responses, 8 | question_dict) 9 | } 10 | \arguments{ 11 | \item{panel_columns}{a list of names of columns desired for inclusion} 12 | 13 | \item{survey_responses}{a response set data frame imported from the Qualtrics CSV responses} 14 | 15 | \item{lean_responses}{an optionally included data frame generated by the lean_responses() function} 16 | 17 | \item{question_dict}{an optionally included data frame generated by the create_response_column_dictionary() function} 18 | } 19 | \description{ 20 | The user provides this function a character vector of names of response columns ( 21 | as the panel_columns var), along with the response set data frame, and the returned 22 | data is a data frame with respondent IDs and column(s) for each column specified. 23 | If the optional parameters, lean_responses and question_dict are provided, then 24 | the function will use them to include a "Raw Response" and a "Coded Response" 25 | column for any columns which are question response columns. 26 | } 27 | -------------------------------------------------------------------------------- /man/create_question_dictionary.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{create_question_dictionary} 4 | \alias{create_question_dictionary} 5 | \title{Create a Question Dictionary} 6 | \usage{ 7 | create_question_dictionary(blocks, flow) 8 | } 9 | \arguments{ 10 | \item{blocks}{The blocks provided to this function must include questions inserted into 11 | the BlockElements. Create the list of blocks from a survey with blocks_from_survey(), 12 | and with questions on hand, insert them into the blocks with questions_into_blocks().} 13 | 14 | \item{flow}{A list of strings identifying the blocks in the order that they appear 15 | within the survey.} 16 | } 17 | \value{ 18 | A data frame with a row for each question describing the question's details. 19 | } 20 | \description{ 21 | Create a Question Dictionary 22 | } 23 | -------------------------------------------------------------------------------- /man/create_response_column_dictionary.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{create_response_column_dictionary} 4 | \alias{create_response_column_dictionary} 5 | \title{Create a Response Column Dictionary} 6 | \usage{ 7 | create_response_column_dictionary(question_blocks, original_first_row, flow) 8 | } 9 | \arguments{ 10 | \item{question_blocks}{use questions_into_blocks() to create a list of blocks with 11 | the survey's questions inserted appropriately into them.} 12 | 13 | \item{original_first_row}{this is the first row of the response data CSV, it is 14 | automatically provided to you when you use get_setup() or in the shiny application.} 15 | 16 | \item{flow}{A list of strings identifying the blocks in the order that they appear 17 | within the survey.} 18 | } 19 | \value{ 20 | a dataframe detailing in each row the response columns and their description. 21 | } 22 | \description{ 23 | By providing the questions structured by their blocks and the original first 24 | row of the response CSV from Qualtrics, this function is able to create a 25 | dictionary where each row is an entry for a response column. The response 26 | columns are listed along with the data export tag of the question they correspond 27 | to, their question stem and question choice, the question types (1, 2, and 3 levels 28 | of question types!), and the response type. 29 | } 30 | -------------------------------------------------------------------------------- /man/create_response_lookup_table.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{create_response_lookup_table} 4 | \alias{create_response_lookup_table} 5 | \title{Create a Lookup Table for Response Variables} 6 | \usage{ 7 | create_response_lookup_table(question) 8 | } 9 | \arguments{ 10 | \item{question}{A list of questions extracted from a Qualtrics QSF file with 11 | responses inserted into them.} 12 | } 13 | \value{ 14 | A dataframe with columns "var", "recode_value", and "text", where each 15 | row corresponds to a unique variable response to the question. 16 | } 17 | \description{ 18 | For each variable response in the responses to a question, 19 | this function creates a row which contains the variable, 20 | its recode value if the question uses recode values, and the 21 | corresponding text for the given variable response. The exact 22 | format of the output lookup table (dataframe) is dictated 23 | by the question type depending on whether it is a 24 | multiple answer question, a multiple choice single answer question, 25 | or a matrix single answer question. Note that this function 26 | only creates a lookup table for each response which appears in the responses. 27 | } 28 | -------------------------------------------------------------------------------- /man/directory_get_coded_comment_sheets.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{directory_get_coded_comment_sheets} 4 | \alias{directory_get_coded_comment_sheets} 5 | \title{Turn a Directory into a list of Coded Comment Data Frames (unprocessed)} 6 | \usage{ 7 | directory_get_coded_comment_sheets(directory) 8 | } 9 | \arguments{ 10 | \item{directory}{A string path to the directory containing the coded comments 11 | sheets, which are formatted as described in the Wiki. 12 | https://github.com/ctesta01/QualtricsTools/wiki/Comment-Coding} 13 | } 14 | \value{ 15 | A list of dataframes for each sheet of coded comments. 16 | } 17 | \description{ 18 | This function takes as an argument a string representative of a 19 | directory, loads the CSVs and Excel data from that directory, 20 | looks for 'Coded' sheets, extracts the coded sheets, 21 | and saves the coded comment table and the question ID 22 | as a pair in the output coded_appendix_tables list. If there 23 | are sheets which contain non-numeric data, warnings are raised. 24 | } 25 | -------------------------------------------------------------------------------- /man/display_logic_from_question.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{display_logic_from_question} 4 | \alias{display_logic_from_question} 5 | \title{Return a list of a Question's Display Logic Components} 6 | \usage{ 7 | display_logic_from_question(question) 8 | } 9 | \arguments{ 10 | \item{question}{A qualtrics survey question} 11 | } 12 | \value{ 13 | an ordered list of display logic messages 14 | } 15 | \description{ 16 | For each question, if they appear, go through the 17 | Question's DisplayLogic, each Choice's DisplayLogic, and 18 | each Answer's DisplayLogic. For each of them, use clean_html 19 | to format them, and then add them to the list. If a question 20 | has any of these display logic components, insert before 21 | adding any display logic a line detailing what part of the 22 | question the following display logic corresponds to. 23 | } 24 | -------------------------------------------------------------------------------- /man/find_question.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{find_question} 4 | \alias{find_question} 5 | \title{Find Question from DataExportTag} 6 | \usage{ 7 | find_question(questions, exporttag) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a Qualtrics survey.} 11 | 12 | \item{exporttag}{A string data export tag to identify the 13 | desired question.} 14 | } 15 | \value{ 16 | The question list object, such that 17 | find_question(...)[['Payload']][['DataExportTag']] == exporttag 18 | } 19 | \description{ 20 | This function takes a list of questions and an export tag and 21 | looks for the matching question. It will try to select 22 | the question uniquely. 23 | } 24 | -------------------------------------------------------------------------------- /man/find_question_index.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{find_question_index} 4 | \alias{find_question_index} 5 | \title{Find Question Index from DataExportTag} 6 | \usage{ 7 | find_question_index(questions, exporttag) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a Qualtrics survey.} 11 | 12 | \item{exporttag}{A string data export tag to identify the 13 | desired question.} 14 | } 15 | \value{ 16 | A numeric list with entries such that 17 | questions[[i]][['Payload']][['DataExportTag]] == exporttag 18 | for any i in the returned list. 19 | } 20 | \description{ 21 | Similar to find_question and find_question, this function 22 | takes a list of questions and an export tag and 23 | looks for the matching question. Differently from find_question, 24 | this function returns the index of 25 | the questions with that Question Data Export Tag rather than 26 | the question itself. 27 | } 28 | -------------------------------------------------------------------------------- /man/find_question_index_by_qid.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{find_question_index_by_qid} 4 | \alias{find_question_index_by_qid} 5 | \title{Find a Question by its QuestionID} 6 | \usage{ 7 | find_question_index_by_qid(questions, qid) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a Qualtrics survey.} 11 | 12 | \item{qid}{A string QuestionID to match} 13 | } 14 | \value{ 15 | A numeric list with entries such that 16 | questions[[i]][['Payload']][['DataExportTag']] == qid 17 | } 18 | \description{ 19 | This function takes a list of questions and a Question ID and 20 | looks for the question with a matching Question ID. The function 21 | returns the index of the matching question. 22 | } 23 | -------------------------------------------------------------------------------- /man/flow_from_survey.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{flow_from_survey} 4 | \alias{flow_from_survey} 5 | \title{Get the Flow out of the Survey} 6 | \usage{ 7 | flow_from_survey(survey) 8 | } 9 | \arguments{ 10 | \item{survey}{A qualtrics survey list object, 11 | uploaded from a Qualtrics Survey File (QSF). Use 12 | ask_for_qsf() to create such a survey list object from a QSF file.} 13 | } 14 | \value{ 15 | A list of strings identifying the blocks in the order that they appear 16 | within the survey. 17 | } 18 | \description{ 19 | The 'Flow' is a list of Block IDs in the order that they are presented 20 | in the survey as it is taken by a respondent. The flow list that is returned 21 | from this function is used by functions like text_appendices_table and 22 | create_html_results_tables to get the ordering of the survey in the preview correct. 23 | } 24 | -------------------------------------------------------------------------------- /man/format_and_split_comment_sheets.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{format_and_split_comment_sheets} 4 | \alias{format_and_split_comment_sheets} 5 | \title{Format and Split a list of Unprocessed Coded Comment Sheets} 6 | \usage{ 7 | format_and_split_comment_sheets(coded_comment_sheets, responses, split_column) 8 | } 9 | \arguments{ 10 | \item{coded_comment_sheets}{A list of dataframes for 11 | each sheet of coded comments.} 12 | 13 | \item{responses}{A dataframe of Qualtrics responses to a survey. 14 | Use ask_for_csv() to create such a dataframe from a CSV file.} 15 | 16 | \item{split_column}{The string name of the column across which the coded comments 17 | should be split.} 18 | } 19 | \value{ 20 | A list of lists, for each split group, and for the pairs of question IDs with 21 | coded comment tables in each split group. 22 | } 23 | \description{ 24 | When splitting the respondents of a survey to create split reports, 25 | the coded comments are split by this function and then returned as a list of lists. 26 | The first list is a list for each split group, and each list within those is a 27 | list of pairs of question IDs and their coded comments tables. 28 | } 29 | -------------------------------------------------------------------------------- /man/format_coded_comment_sheets.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{format_coded_comment_sheets} 4 | \alias{format_coded_comment_sheets} 5 | \title{Format Comment Coding Data into Frequency Tables} 6 | \usage{ 7 | format_coded_comment_sheets(coded_comment_sheets) 8 | } 9 | \arguments{ 10 | \item{coded_comment_sheets}{A list of dataframes for 11 | each sheet of coded comments.} 12 | } 13 | \value{ 14 | A list of pairs (varname, coded_table) where varname corresponds 15 | to the response column name of the comments coded and coded_table 16 | summarizes the frequencies of the provided coded comments. 17 | } 18 | \description{ 19 | This function takes as an argument a list of dataframes 20 | which categorize the text responses to a free-response 21 | component of a survey and formats them into a standardized 22 | frequency table by applying format_coded_comments to each 23 | coded_comment_sheet. 24 | } 25 | -------------------------------------------------------------------------------- /man/format_coded_comments.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{format_coded_comments} 4 | \alias{format_coded_comments} 5 | \title{Process a Dataframe of Coded Comments} 6 | \usage{ 7 | format_coded_comments(coded_comment_sheet) 8 | } 9 | \arguments{ 10 | \item{coded_comment_sheet}{A single dataframe, imported from a 11 | file in the format as specified by the wiki. 12 | https://github.com/ctesta01/QualtricsTools/wiki/Comment-Coding} 13 | } 14 | \value{ 15 | A pair (varname, coded_table) where varname corresponds 16 | to the corresponding original response column name and coded_table 17 | summarizes the frequencies of the provided coded comments. 18 | } 19 | \description{ 20 | This turns the original dataframe of coded comments 21 | into a pair (varname, coded_table), where the varname 22 | is the column name in the response CSV data from Qualtrics 23 | that the coded comments correspond to and coded_table 24 | summarizes the responses to the coded comments with 25 | frequencies for each coded category. 26 | } 27 | -------------------------------------------------------------------------------- /man/generate_results.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{generate_results} 4 | \alias{generate_results} 5 | \title{Create Results Tables and Pair Them to Questions} 6 | \usage{ 7 | generate_results(questions, original_first_rows) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a Qualtrics Survey File containing 11 | response columns (inserted by link_responses_to_questions).} 12 | 13 | \item{original_first_rows}{A dataframe contianing the header information 14 | for each column of response data. This dataframe includes a row for the DataExportTag based 15 | response column names, another for the Question Text stem and choice text (although 16 | truncated), and a row with QID based column names.} 17 | } 18 | \value{ 19 | A list of questions with their results tables paired to them 20 | under the questions[[i]][['Table']] 21 | } 22 | \description{ 23 | The generate_results function takes a list of questions which have 24 | their responses paired to them, determines their question type, 25 | uses the results generation functions to create their results table, 26 | and saves the table to the question's [['Table']] element. The function 27 | returns the list of questions with their paired results tables. 28 | } 29 | -------------------------------------------------------------------------------- /man/get_coded_comment_sheet.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{get_coded_comment_sheet} 4 | \alias{get_coded_comment_sheet} 5 | \title{Turn a Single Coded File into a Data Frame} 6 | \usage{ 7 | get_coded_comment_sheet(codedfile) 8 | } 9 | \arguments{ 10 | \item{codedfile}{The string path to a Excel file.} 11 | } 12 | \value{ 13 | A dataframe version of the contents of the coded comments 14 | in the codedfile. 15 | } 16 | \description{ 17 | This retrieves comment coding data as a dataframe 18 | from a Excel file. Coded comments are retrieved from the sheet named "Coded" 19 | (case does not matter). 20 | } 21 | -------------------------------------------------------------------------------- /man/get_reorganized_questions_and_blocks.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{get_reorganized_questions_and_blocks} 4 | \alias{get_reorganized_questions_and_blocks} 5 | \title{Get Restructured Questions (with inserted Responses) 6 | and Blocks (with inserted Questions) from data 7 | provided by Qualtrics.} 8 | \usage{ 9 | get_reorganized_questions_and_blocks(survey, responses, original_first_rows) 10 | } 11 | \arguments{ 12 | \item{survey}{A qualtrics survey list object, 13 | uploaded from a Qualtrics Survey File (QSF). Use 14 | ask_for_qsf() to create such a survey list object from a QSF file.} 15 | 16 | \item{responses}{A dataframe of Qualtrics responses to a survey. 17 | Use ask_for_csv() to create such a dataframe from a CSV file.} 18 | 19 | \item{original_first_rows}{A dataframe contianing the header information 20 | for each column of response data. This dataframe includes a row for the DataExportTag based 21 | response column names, another for the Question Text stem and choice text (although 22 | truncated), and a row with QID based column names.} 23 | } 24 | \value{ 25 | A list with two elements: the questions, 26 | and the survey blocks. All questions in the trash are 27 | excluded, HTML and CSS are removed from question text, 28 | responses, notes, and a more easily human readable question 29 | type are inserted into each question. The blocks then have 30 | their BlockElements replaced by corresponding questions 31 | where applicable. The BlockElements of the list of Blocks 32 | from a survey originally only refer to questions 33 | by their DataExportTag. However, this is inconvenient 34 | because it adds an additional lookup step, and so they are 35 | replaced by the real objects here. 36 | } 37 | \description{ 38 | This function returns a list with two elements, where 39 | the first element is questions with their responses 40 | and results-tables listed in them, and secondly 41 | the blocks of the survey, with questions listed in 42 | each block as BlockElements. 43 | } 44 | -------------------------------------------------------------------------------- /man/get_setup.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{get_setup} 4 | \alias{get_setup} 5 | \title{Setup the Global Environment for a Survey} 6 | \usage{ 7 | get_setup(qsf_path, csv_path, headerrows, already_loaded, 8 | return_data_as_list = FALSE, sample_data = FALSE) 9 | } 10 | \arguments{ 11 | \item{qsf_path}{The string location of the survey as a .QSF (Qualtrics Survey File)} 12 | 13 | \item{csv_path}{The string location of the survey's responses, downloaded from Qualtrics} 14 | 15 | \item{headerrows}{An optional parameter for specifying the number of 16 | headerrows in the response csv. While the headerrows parameter can functionally 17 | be set to any number, users predominantly should expect to use headerrows equal to 18 | 2 or 3 depending on whether or not their response data was downloaded from Qualtrics 19 | before or after the rollout of the new Qualtrics Insights platform. In the 20 | Qualtrics Insights platform, there are 3 headerrows, while before this update there 21 | were only 2.} 22 | 23 | \item{already_loaded}{already_loaded=TRUE indicates that get_setup should 24 | get the survey, responses, and original_first_rows from the global scope 25 | instead of asking the user for them. This parameter is optional and defaults to FALSE.} 26 | 27 | \item{return_data_as_list}{An optional boolean parameter which dictates whether the processed 28 | survey data should be returned to the global scope if return_data_as_list=FALSE or is missing, 29 | or if the processed should be returned as a list in the order 30 | c(survey, responses, questions, blocks, original_first_rows, flow) if return_data_as_list=TRUE.} 31 | 32 | \item{sample_data}{An optional boolean parameter which when true makes get_setup load the 33 | sample survey data included with the QualtricsTools package. The sample data stored with 34 | the package is stored in the data/sample_*.rda files. The sample data stored there is 35 | Insights formatted data with 3 headerrows.} 36 | } 37 | \description{ 38 | This function sets the user up with the survey, responses, questions, 39 | blocks, questions, original_first_rows, and flow. By default, these are 40 | returned to the global scope (referred to by .GlobalEnv or globalenv()). 41 | If return_data_as_list is passed as TRUE, then the data is returned from 42 | the function as a list. The blocks and questions are redundant as they 43 | are already included in the survey, but they are often useful to 44 | have already pulled out of the survey. Among the many processing steps this 45 | function (made both directly and as subsequent nested function calls), the question 46 | text is cleaned and stripped of HTML and any unwanted characters, 47 | the trash questions and blocks are removed, response columns are matched 48 | and inserted into the corresponding questions, and results tables detailing 49 | the frequencies and breakdowns of respondents among each question's choices 50 | are automatically inserted into each applicable question. This function can 51 | be called in multiple ways, specifying the parameters explicitly, or by 52 | specifying them interactively. For example, calling get_setup() with no 53 | parameters will result in a prompt asking for the number of headerrows in 54 | your response data and two subsequent dialogue boxes asking the user 55 | to choose the corresponding QSF and CSV files. If already_loaded=TRUE is 56 | passed, then the get_setup function pulls the survey list and responses 57 | dataframe from the global environment. If 58 | sample_data=TRUE is passed, then a sample survey is loaded. 59 | } 60 | \examples{ 61 | # An Interactive Example 62 | 63 | > get_setup() 64 | Enter the number of response data header rows [Default: 3]: 65 | Defaulting to headerrows=3 66 | [1] "Select Qualtrics Survey File:" 67 | [1] "Select CSV Response File:" 68 | 69 | survey, responses, questions, blocks, original_first_rows, 70 | and flow are now global variables. 71 | 72 | # An Explicit Example 73 | 74 | > get_setup( 75 | qsf_path = "C:/Example/Path/to/QSF/File.qsf", 76 | csv_path = "C:/Example/Path/to/CSV/File.csv", 77 | headerrows = 3) 78 | 79 | survey, responses, questions, blocks, original_first_rows, 80 | and flow are now global variables. 81 | 82 | # An Example with return_data_as_list=TRUE 83 | 84 | > qualtricstools_values = get_setup( 85 | qsf_path = "C:/Example/Path/to/QSF/File.qsf", 86 | csv_path = "C:/Example/Path/to/CSV/File.csv", 87 | headerrows = 3, 88 | return_data_as_list=TRUE) 89 | 90 | > varnames = c( 91 | 'survey', 'responses', 'questions', 'blocks', 92 | 'original_first_rows', 'flow') 93 | > for (i in 1:length(varnames)) 94 | assign(varnames[[i]], qualtricstools_values[[i]]) 95 | > rm(qualtricstools_values, varnames, i) 96 | > ls() 97 | 98 | [1] "blocks" "flow" "original_first_rows" 99 | [5] "questions" "responses" "survey" 100 | 101 | # Loading a Sample Survey 102 | 103 | > get_setup(sample_data=TRUE) 104 | 105 | survey, responses, questions, blocks, original_first_rows, 106 | and flow are now global variables. 107 | } 108 | -------------------------------------------------------------------------------- /man/get_setup_in_environment.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{get_setup_in_environment} 4 | \alias{get_setup_in_environment} 5 | \title{Load Survey Data into an Arbitrary Environment in R} 6 | \usage{ 7 | get_setup_in_environment(qsf_path, csv_path, headerrows, environment) 8 | } 9 | \arguments{ 10 | \item{qsf_path}{The string location of the survey as a .QSF (Qualtrics Survey File)} 11 | 12 | \item{csv_path}{The string location of the survey's responses, downloaded from Qualtrics} 13 | 14 | \item{headerrows}{An optional parameter for specifying the number of 15 | headerrows in the response csv.} 16 | 17 | \item{environment}{An R environment to save each of the survey, responses, questions, blocks 18 | original_first_rows, and flow into.} 19 | } 20 | \description{ 21 | This function puts the survey, responses, questions, blocks 22 | original_first_rows, and flow into the environment specified in R. 23 | qsf_path, csv_path, and headerrows are optional. If qsf_path and 24 | csv_path are provided, then the function uses get_setup with return_data_as_list 25 | to process the survey data and then insert the returned data into the 26 | specified environment. If the qsf_path and csv_path are not specified, 27 | the function first checks the global scope to see if all output from 28 | get_setup exists, and if so, the function copies them into the specified 29 | environment. If the qsf_path and csv_path are not provided, and the 30 | output of get_setup is not in the global scope, then the function calls 31 | get_setup to interactively ask the user to select the qsf_path and csv_path. 32 | Headerrows is defaulted to 3 by the get_setup function if it is not provided. 33 | } 34 | -------------------------------------------------------------------------------- /man/html_2_pandoc.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/pandoc_conversion.R 3 | \name{html_2_pandoc} 4 | \alias{html_2_pandoc} 5 | \title{Convert HTML to a Docx File} 6 | \usage{ 7 | html_2_pandoc(html, file_name, format, output_dir) 8 | } 9 | \arguments{ 10 | \item{html}{an html body contents string. Do not include the ... tags, 11 | the html parameter will automatically have those kinds of tags added within this 12 | function.} 13 | 14 | \item{output_dir}{an optional parameter for specifying an output folder} 15 | } 16 | \value{ 17 | the path to the docx file created from converting the html. 18 | } 19 | \description{ 20 | This function uses pandoc and tempfiles to create a docx version 21 | of an HTML document. The HTML is prepended and appended with 22 | and . Then it is saved 23 | to a tempfile, and then pandoc converts it to a .docx file. Finally, 24 | the path to the .docx file is returned. 25 | } 26 | -------------------------------------------------------------------------------- /man/human_readable_qtype.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{human_readable_qtype} 4 | \alias{human_readable_qtype} 5 | \title{Create Human Readable Question Types} 6 | \usage{ 7 | human_readable_qtype(questions) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions extracted from a Qualtrics QSF file. Use 11 | questions_from_survey() to get them from an imported survey.} 12 | } 13 | \value{ 14 | A list of questions which include in their Payload a QuestionTypeHuman field. 15 | } 16 | \description{ 17 | This function saves, admittedly reductionist, more friendly question type 18 | descriptions. It doesn't have human human readable versions for every question type, 19 | but for some it is useful to reduce the question type to something more simple. 20 | This has a nested function (create_qtype) that determines a question's human question type, 21 | and then it loops through the questions and saves to each the QuestionTypeHuman 22 | field with the output of create_qtype. 23 | } 24 | -------------------------------------------------------------------------------- /man/insert_coded_comments.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{insert_coded_comments} 4 | \alias{insert_coded_comments} 5 | \title{Insert Coded Comments into Blocks} 6 | \usage{ 7 | insert_coded_comments(blocks, original_first_rows, coded_comments) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of the survey blocks, with the questions included in them.} 11 | 12 | \item{original_first_rows}{A dataframe contianing the header information 13 | for each column of response data. This dataframe should include a row for the DataExportTag based 14 | response column names, another for the Question Text stem and choice text (although 15 | truncated), and a row with QID based column names.} 16 | 17 | \item{coded_comments}{A list of pairs (varname, coded_table) where varname corresponds 18 | to the response column name of the comments coded and coded_table 19 | summarizes the frequencies of the provided coded comments.} 20 | } 21 | \description{ 22 | This takes a list of pairs of question IDs and coded comments tables 23 | and finds their corresponding question based on the question ID in a list 24 | of blocks and then inserts the coded comments table into the question. 25 | The returned list is a list of blocks where the questions have had their 26 | coded comments inserted. 27 | } 28 | -------------------------------------------------------------------------------- /man/insert_notes_into_questions.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{insert_notes_into_questions} 4 | \alias{insert_notes_into_questions} 5 | \title{Insert the Notes for a question into its qtNotes} 6 | \usage{ 7 | insert_notes_into_questions(questions, notes) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions selected from a Qualtrics survey} 11 | 12 | \item{notes}{A list of blocks with type element "NT"} 13 | } 14 | \description{ 15 | Insert the Notes for a question into its qtNotes 16 | } 17 | -------------------------------------------------------------------------------- /man/insert_split_survey_comments.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{insert_split_survey_comments} 4 | \alias{insert_split_survey_comments} 5 | \title{Split Survey and Insert Split Coded Comments} 6 | \usage{ 7 | insert_split_survey_comments(split_blocks, split_coded_comment_sheets, 8 | split_column, original_first_rows) 9 | } 10 | \arguments{ 11 | \item{split_blocks}{A list of a list of blocks. The same question, but with different respondent groups, 12 | might look something like split_blocks[[1]][[1]][['BlockElements']][[1]] and 13 | split_blocks[[2]][[1]][['BlockElements']][[1]]. These refer to the first and second respondent 14 | groups, the first block, and the first block element. Split blocks of this form are 15 | generated by the split_respondents function.} 16 | 17 | \item{split_coded_comment_sheets}{A list of lists where the outer lists each split group 18 | and the inner lists the pairs of question IDs with coded comment tables in each split group.} 19 | 20 | \item{split_column}{The string name of the column across which the coded comments 21 | should be split.} 22 | 23 | \item{original_first_rows}{A dataframe contianing the header information 24 | for each column of response data. This dataframe should include a row for the DataExportTag based 25 | response column names, another for the Question Text stem and choice text (although 26 | truncated), and a row with QID based column names.} 27 | } 28 | \value{ 29 | The returned data is a list of lists of blocks. Each list of blocks has the coded comments 30 | for a specific respondent group inserted into them, and each of the lists of blocks in the 31 | output corresponds to a specific respondent group. The list of blocks is duplicated for each 32 | respondent group, and then that respondent group's coded comments are inserted into each 33 | list of blocks. 34 | } 35 | \description{ 36 | This function splits the survey's response data and the 37 | coded comments, then inserts the split coded comments into the split 38 | surveys. 39 | } 40 | -------------------------------------------------------------------------------- /man/is_matrix_bipolar.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_matrix_bipolar} 4 | \alias{is_matrix_bipolar} 5 | \title{Determine if a question is a matrix and multiple answer question} 6 | \usage{ 7 | is_matrix_bipolar(question) 8 | } 9 | \arguments{ 10 | \item{question}{The question parameter is a single question from a qualtrics survey.} 11 | } 12 | \value{ 13 | The return value of this is a boolean, true if it is one of these kinds of 14 | questions and false otherwise. 15 | } 16 | \description{ 17 | A question is considered a matrix multiple answer question if it 18 | is a `[['Payload']][['QuestionType']] == "Matrix"` question with 19 | `[['Payload']][['SubSelector']] == "SingleAnswer"` or `[['Payload']][['SubSelector']] == "DL"` 20 | } 21 | -------------------------------------------------------------------------------- /man/is_matrix_multiple_answer.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_matrix_multiple_answer} 4 | \alias{is_matrix_multiple_answer} 5 | \title{Determine if a question is a matrix and multiple answer question} 6 | \usage{ 7 | is_matrix_multiple_answer(question) 8 | } 9 | \arguments{ 10 | \item{question}{The question parameter is a single question from a qualtrics survey.} 11 | } 12 | \value{ 13 | The return value of this is a boolean, true if it is one of these kinds of 14 | questions and false otherwise. 15 | } 16 | \description{ 17 | A question is considered a matrix multiple answer question if it 18 | is a `[['Payload']][['QuestionType']] == "Matrix"` question with 19 | `[['Payload']][['SubSelector']] == "MultipleAnswer"` 20 | } 21 | -------------------------------------------------------------------------------- /man/is_matrix_question.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_matrix_question} 4 | \alias{is_matrix_question} 5 | \title{Determine if a question is a matrix question} 6 | \usage{ 7 | is_matrix_question(x) 8 | } 9 | \description{ 10 | Determine if a question is a matrix question 11 | } 12 | -------------------------------------------------------------------------------- /man/is_matrix_single_answer.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_matrix_single_answer} 4 | \alias{is_matrix_single_answer} 5 | \title{Determine if a question is a matrix and multiple answer question} 6 | \usage{ 7 | is_matrix_single_answer(question) 8 | } 9 | \arguments{ 10 | \item{question}{The question parameter is a single question from a qualtrics survey.} 11 | } 12 | \value{ 13 | The return value of this is a boolean, true if it is one of these kinds of 14 | questions and false otherwise. 15 | } 16 | \description{ 17 | A question is considered a matrix multiple answer question if it 18 | is a `[['Payload']][['QuestionType']] == "Matrix"` question with 19 | `[['Payload']][['SubSelector']] == "SingleAnswer"` or `[['Payload']][['SubSelector']] == "DL"` 20 | } 21 | -------------------------------------------------------------------------------- /man/is_mc_multiple_answer.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_mc_multiple_answer} 4 | \alias{is_mc_multiple_answer} 5 | \title{Determine if a question is a multiple choice and multiple answer question} 6 | \usage{ 7 | is_mc_multiple_answer(question) 8 | } 9 | \arguments{ 10 | \item{question}{The question parameter is a single question from a qualtrics survey.} 11 | } 12 | \value{ 13 | The return value of this is a boolean, true if it is one of these kinds of 14 | questions and false otherwise. 15 | } 16 | \description{ 17 | Each of the is-functions defined in the qualtrics package are used 18 | for determining which response parsing function should be used. A 19 | function is considered multiple choice if it is listed in 20 | the qsf file as having [['Payload']][['QuestionType']] == "MC" 21 | (standing for Multiple Choice), and the `[['Payload']][['Selector']]` is set to one of the 22 | following: 23 | "Multiple Answer Vertical", 24 | "Multiple Answer Horizontal", 25 | "Multiple Choice Select Box", 26 | "Multiple Answer Column", 27 | } 28 | -------------------------------------------------------------------------------- /man/is_mc_single_answer.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_mc_single_answer} 4 | \alias{is_mc_single_answer} 5 | \title{Determine if a question is a single answer question} 6 | \usage{ 7 | is_mc_single_answer(question) 8 | } 9 | \arguments{ 10 | \item{question}{The question parameter is a single question from a qualtrics survey.} 11 | } 12 | \value{ 13 | The return value of this is a boolean, true if it is one of these kinds of 14 | questions and false otherwise. 15 | } 16 | \description{ 17 | Each of the is-functions defined in the qualtrics package are used 18 | for determining which response parsing function should be used. A 19 | function is considered multiple choice if it is listed in 20 | the qsf file as having [['Payload']][['QuestionType']] == "MC" 21 | (standing for Multiple Choice), and the `[['Payload']][['Selector']]` is set to one of the 22 | following: 23 | "Single Answer Vertical", 24 | "Single Answer Horizontal", 25 | "Single Answer Column", 26 | "Dropdown List", 27 | "Select Box", 28 | } 29 | -------------------------------------------------------------------------------- /man/is_multiple_answer.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_multiple_answer} 4 | \alias{is_multiple_answer} 5 | \title{Determine if a question is a multiple answer question} 6 | \usage{ 7 | is_multiple_answer(x) 8 | } 9 | \description{ 10 | Determine if a question is a multiple answer question 11 | } 12 | -------------------------------------------------------------------------------- /man/is_rank_order.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_rank_order} 4 | \alias{is_rank_order} 5 | \title{Determine if a question is a rank order question} 6 | \usage{ 7 | is_rank_order(x) 8 | } 9 | \description{ 10 | Determine if a question is a rank order question 11 | } 12 | -------------------------------------------------------------------------------- /man/is_single_answer.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_single_answer} 4 | \alias{is_single_answer} 5 | \title{Determine if a question is a single answer question} 6 | \usage{ 7 | is_single_answer(x) 8 | } 9 | \description{ 10 | Determine if a question is a single answer question 11 | } 12 | -------------------------------------------------------------------------------- /man/is_text_entry.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/question_type_checking.R 3 | \name{is_text_entry} 4 | \alias{is_text_entry} 5 | \title{Determine if a question is a text entry question} 6 | \usage{ 7 | is_text_entry(x) 8 | } 9 | \description{ 10 | Determine if a question is a text entry question 11 | } 12 | -------------------------------------------------------------------------------- /man/lean_responses.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{lean_responses} 4 | \alias{lean_responses} 5 | \title{Create Long and Lean Response Dictionary} 6 | \usage{ 7 | lean_responses(question_blocks, survey_responses, include_text_entry = FALSE) 8 | } 9 | \arguments{ 10 | \item{question_blocks}{A list of blocks, with questions inserted in place of the 11 | BlockElements representing them.} 12 | 13 | \item{survey_responses}{The responses to the survey, as imported by ask_for_csv()} 14 | 15 | \item{include_text_entry}{A parameter which defaults to FALSE indicating whether or not 16 | open ended text responses should be included in the dictionary of lean responses.} 17 | } 18 | \value{ 19 | a data frame with each row detailing an individual survey response. 20 | } 21 | \description{ 22 | lean_responses() creates a data frame where each row corresponds to 23 | an individual response to the survey. Each response contains 24 | the respondents' id, the response column's name, 25 | the variable response, and the coded 26 | response. 27 | } 28 | -------------------------------------------------------------------------------- /man/link_responses_to_questions.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{link_responses_to_questions} 4 | \alias{link_responses_to_questions} 5 | \title{Link Responses to Questions} 6 | \usage{ 7 | link_responses_to_questions(questions, responses, original_first_rows) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions selected from a Qualtrics survey} 11 | 12 | \item{responses}{A data frame of responses from a Qualtrics survey} 13 | 14 | \item{original_first_rows}{The original header rows to the CSV response set} 15 | } 16 | \value{ 17 | The updated list of questions, each including its relevant response columns 18 | as a data frame stored in [['Responses']]. 19 | } 20 | \description{ 21 | The columns of the response data must be matched up to their corresponding 22 | questions and question-parts in order to analyze them. One of two methods is employed, depending 23 | on whether or not the original_first_rows are from Insights or Legacy data. 24 | } 25 | \details{ 26 | If Insights data is used, each question is looped through and the QuestionIDs are used to 27 | match response columns to a question. 28 | 29 | Otherwise, a much more complicated process is used: 30 | each question is looped through, determining the DataExportTag of the question, 31 | and the ChoiceDataExportTags of the question. The DataExportTag might look 32 | like a variable name that has been set by the user in Qualtrics, or an 33 | automatically generated name like "QID1" or "QID1.1". The columns 34 | with names automatically generated by Qualtrics usually are of a form 35 | starting with the DataExportTag, followed by an underscore, and then more details. 36 | Sometimes they are exactly the DataExportTag without any modification. Lastly, 37 | if the user sets their own variable naming in Qualtrics, then the question 38 | contains in its [['Payload']] the [['ChoiceDataExportTags']] list, which contains 39 | these user defined variables. This function goes through each question, 40 | determines the DataExportTag and ChoiceDataExportTags, and uses each to select 41 | the matching columns of the responses. Those are then inserted into that specific 42 | question under [['Responses']], and the whole questions list is returned. One small 43 | caveat is that if the column name starts with an integer, then R 44 | will prepend it with an "X", so there is a helper function included here to include 45 | those columns with prepended "X"s as well. 46 | } 47 | -------------------------------------------------------------------------------- /man/load_csv_data.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/loading_files.R 3 | \name{load_csv_data} 4 | \alias{load_csv_data} 5 | \title{Set Response Data to Sample Data or User Data} 6 | \usage{ 7 | load_csv_data(file2, file1, headerrows) 8 | } 9 | \arguments{ 10 | \item{file1}{This should be a CSV received from a file upload made in the Shiny UI, 11 | which includes a file1[['datapath']] where the data can be located.} 12 | } 13 | \value{ 14 | The return value is the responses data frame 15 | } 16 | \description{ 17 | load_csv_data returns the sample response set or the user's response set depending 18 | on whether or not the user has uploaded data. 19 | } 20 | -------------------------------------------------------------------------------- /man/load_qsf_data.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/loading_files.R 3 | \name{load_qsf_data} 4 | \alias{load_qsf_data} 5 | \title{Set Survey to Sample Survey or User Survey} 6 | \usage{ 7 | load_qsf_data(file1) 8 | } 9 | \arguments{ 10 | \item{file2}{This should be a QSF file received 11 | from a file upload made in the Shiny UI, 12 | which includes a file1[['datapath']] where the data can be located.} 13 | } 14 | \value{ 15 | The return value is the survey list object 16 | } 17 | \description{ 18 | load_qsf_data returns the sample survey 19 | or the user's survey depending 20 | on whether or not the user has uploaded data. 21 | } 22 | -------------------------------------------------------------------------------- /man/make_coded_comments.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{make_coded_comments} 4 | \alias{make_coded_comments} 5 | \title{Create Text Appendices including Coded Comments} 6 | \usage{ 7 | make_coded_comments(qsf_path, csv_path, headerrows, sheets_dir, output_dir, 8 | filename = "Text Appendices with Coded Comments.docx", n_threshold = 15) 9 | } 10 | \arguments{ 11 | \item{qsf_path}{(optional) is the string path location of the .qsf file to be processed.} 12 | 13 | \item{csv_path}{(optional) is the string path location of the .csv file to be processed.} 14 | 15 | \item{headerrows}{(optional) specifies the number of header rows in the CSV data.} 16 | 17 | \item{sheets_dir}{is the string path location of the directory which contains Excel documents 18 | with a "Coded" sheet formatted as specified on the wiki: 19 | https://github.com/ctesta01/QualtricsTools/wiki/Comment-Coding} 20 | 21 | \item{output_dir}{specifies the path of the directory to save the output file in.} 22 | 23 | \item{filename}{specifies the name of the output file.} 24 | 25 | \item{n_threshold}{is the number of verbatim comments which must appear before an appendix of 26 | coded comments will be included.} 27 | } 28 | \description{ 29 | Using `get_setup`, `directory_get_coded_comment_sheets`, `format_coded_comment_sheets`, 30 | `insert_coded_comments`, and `html_2_pandoc`, this function renders 31 | text appendices with coded comments included from CSV or XLSX files 32 | from the specified `sheets_dir` parameter. 33 | } 34 | -------------------------------------------------------------------------------- /man/make_results_tables.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{make_results_tables} 4 | \alias{make_results_tables} 5 | \title{Export a file containing the results tables} 6 | \usage{ 7 | make_results_tables(qsf_path, csv_path, headerrows, output_dir, 8 | filename = "Results Tables.docx") 9 | } 10 | \arguments{ 11 | \item{qsf_path}{(optional) is the string path location of the .qsf file to be processed.} 12 | 13 | \item{csv_path}{(optional) is the string path location of the .csv file to be processed.} 14 | 15 | \item{headerrows}{(optional) specifies the number of header rows in the CSV data.} 16 | 17 | \item{output_dir}{specifies the path of the directory to save the output file in.} 18 | 19 | \item{filename}{specifies the name of the output file.} 20 | } 21 | \description{ 22 | `make_results_tables` uses `get_setup` and `html_2_pandoc` to process a 23 | survey and then save its results into a file. If the `qsf_path,` and `csv_path` 24 | are included as parameters, then they will be passed to `get_setup` along with a 25 | `return_data_as_list=TRUE` parameter in order to return the survey, responses, 26 | questions, blocks, original_first_rows, and flow as variables local to the function 27 | scope. If they are not passed, they will be retrieved as needed from the global scope. 28 | The function then uses the blocks, original_first_rows, and flow with `html_2_pandoc` 29 | to produce the desired output file. 30 | } 31 | -------------------------------------------------------------------------------- /man/make_split_coded_comments.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{make_split_coded_comments} 4 | \alias{make_split_coded_comments} 5 | \title{Split a Survey's Split Coded Comment Appendices} 6 | \usage{ 7 | make_split_coded_comments(qsf_path, csv_path, sheets_dir, output_dir, split_by, 8 | n_threshold = 15, headerrows) 9 | } 10 | \arguments{ 11 | \item{qsf_path}{(optional) is the string path location of the .qsf file to be processed.} 12 | 13 | \item{csv_path}{(optional) is the string path location of the .csv file to be processed.} 14 | 15 | \item{sheets_dir}{is the string path location of the directory which contains Excel documents 16 | with a "Coded" sheet formatted as specified on the wiki: 17 | https://github.com/ctesta01/QualtricsTools/wiki/Comment-Coding} 18 | 19 | \item{output_dir}{specifies the path of the directory to save the output file in.} 20 | 21 | \item{split_by}{is a list which specifies which columns should be used to split the respondents.} 22 | 23 | \item{n_threshold}{is the number of verbatim comments which must appear before an appendix of 24 | coded comments will be included.} 25 | 26 | \item{headerrows}{(optional) specifies the number of header rows in the CSV data.} 27 | } 28 | \description{ 29 | This question automates the entire process of splitting a 30 | survey's text appendices by specific response columns. The QSF 31 | and CSV file are passed as string arguments, 32 | the sheets_dir specifies where the coded comments excel or csv 33 | data is stored, and the output_dir specifies where the split 34 | coded comment appendices should be saved. The n_threshold 35 | specifies how many coded comments there must be before the coded 36 | comment appendices are included, and headerrows is an argument 37 | necessary to process the survey results correctly. 38 | } 39 | -------------------------------------------------------------------------------- /man/make_split_results_tables.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{make_split_results_tables} 4 | \alias{make_split_results_tables} 5 | \title{Generate Results Tables Reports Split (or Grouped By) their entries in a Response Column} 6 | \usage{ 7 | make_split_results_tables(qsf_path, csv_path, output_dir, split_by, 8 | headerrows = 3) 9 | } 10 | \arguments{ 11 | \item{qsf_path}{(optional) is the string path location of the .qsf file to be processed.} 12 | 13 | \item{csv_path}{(optional) is the string path location of the .csv file to be processed.} 14 | 15 | \item{output_dir}{specifies the path of the directory to save the output file in.} 16 | 17 | \item{split_by}{is a list which specifies which columns should be used to split the respondents.} 18 | 19 | \item{headerrows}{(optional) specifies the number of header rows in the CSV data.} 20 | } 21 | \description{ 22 | The make_split_results_table function works by constructing and inserting an additional 23 | column into the responses data frame from which the responses are split. Once the responses 24 | are split, they are inserted into distinct lists of blocks (one list for each split group of 25 | responses) and then results tables reports are rendered from these split blocks. The function 26 | renders these reports by looping over the list of split blocks, naming each report according to 27 | its split respondent group, and saving each file to the specified output_dir. At the simplest 28 | level, this function is about running get_setup, create_merged_response_column, 29 | split_respondents, and html_2_pandoc in the right way to produce split reports. 30 | } 31 | -------------------------------------------------------------------------------- /man/make_split_text_appendices.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{make_split_text_appendices} 4 | \alias{make_split_text_appendices} 5 | \title{Generate Results Tables Reports Split (or Grouped By) their entries in a Response Column} 6 | \usage{ 7 | make_split_text_appendices(qsf_path, csv_path, output_dir, split_by, 8 | n_threshold = 15, headerrows = 3) 9 | } 10 | \arguments{ 11 | \item{qsf_path}{(optional) is the string path location of the .qsf file to be processed.} 12 | 13 | \item{csv_path}{(optional) is the string path location of the .csv file to be processed.} 14 | 15 | \item{output_dir}{specifies the path of the directory to save the output file in.} 16 | 17 | \item{split_by}{is a list which specifies which columns should be used to split the respondents.} 18 | 19 | \item{n_threshold}{is the number of verbatim comments which must appear before an appendix of 20 | coded comments will be included.} 21 | 22 | \item{headerrows}{(optional) specifies the number of header rows in the CSV data.} 23 | } 24 | \description{ 25 | The make_split_text_appendices function works by constructing and inserting an additional 26 | column into the responses data frame from which the responses are split. Once the responses 27 | are split, they are inserted into distinct lists of blocks (one list for each split group of 28 | responses) and then text appendices are rendered from these split blocks. The function 29 | renders these reports by looping over the list of split blocks, naming each report according to 30 | its split respondent group, and saving each file to the specified output_dir. At the simplest 31 | level, this function is about running get_setup, create_merged_response_column, 32 | split_respondents, and html_2_pandoc in the right way to produce split reports. 33 | } 34 | -------------------------------------------------------------------------------- /man/make_text_appendices.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{make_text_appendices} 4 | \alias{make_text_appendices} 5 | \title{Export a file containing the text appendices} 6 | \usage{ 7 | make_text_appendices(qsf_path, csv_path, headerrows, output_dir, 8 | filename = "Text Appendices.docx") 9 | } 10 | \arguments{ 11 | \item{qsf_path}{(optional) is the string path location of the .qsf file to be processed.} 12 | 13 | \item{csv_path}{(optional) is the string path location of the .csv file to be processed.} 14 | 15 | \item{headerrows}{(optional) specifies the number of header rows in the CSV data.} 16 | 17 | \item{output_dir}{specifies the path of the directory to save the output file in.} 18 | 19 | \item{filename}{specifies the name of the output file.} 20 | } 21 | \description{ 22 | make_text_appendices uses get_setup and html_2_pandoc to process a 23 | survey and then save its results into a file. If the qsf_path, and csv_path 24 | are included as parameters, then they will be passed to get_setup along with a 25 | return_data_as_list=TRUE parameter in order to return the survey, responses, 26 | questions, blocks, original_first_rows, and flow as variables local to the function 27 | scope. If they are not passed, they will be retrieved as needed from the global scope. 28 | The function then uses the blocks, original_first_rows, and flow with html_2_pandoc 29 | to produce the desired output file. 30 | } 31 | -------------------------------------------------------------------------------- /man/matrix_multiple_answer_results.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{matrix_multiple_answer_results} 4 | \alias{matrix_multiple_answer_results} 5 | \title{Create the Results Table for a Matrix Multiple Answer Question} 6 | \usage{ 7 | matrix_multiple_answer_results(question, original_first_rows) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. The question must have a paired 12 | response column placed into the question 13 | under [['Responses']]. The insertion of the responses into questions is 14 | handled by link_responses_to_questions.} 15 | 16 | \item{original_first_rows}{A dataframe contianing the header information 17 | for each column of response data. This dataframe includes a row for the DataExportTag based 18 | response column names, another for the Question Text stem and choice text (although 19 | truncated), and a row with QID based column names.} 20 | } 21 | \value{ 22 | a table with the matrix-sub-questions listed in the first column, 23 | a column with the total number of respondents for each subquestion, and 24 | the percentages for each choice for each sub-question. 25 | } 26 | \description{ 27 | Create the Results Table for a Matrix Multiple Answer Question 28 | } 29 | -------------------------------------------------------------------------------- /man/matrix_single_answer_results.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{matrix_single_answer_results} 4 | \alias{matrix_single_answer_results} 5 | \title{Create the Results Table for a Matrix Single Answer Question} 6 | \usage{ 7 | matrix_single_answer_results(question, original_first_rows) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. The question must have a paired 12 | response column placed into the question 13 | under [['Responses']]. The insertion of the responses into questions is 14 | handled by link_responses_to_questions.} 15 | 16 | \item{original_first_rows}{A dataframe contianing the header information 17 | for each column of response data. This dataframe includes a row for the DataExportTag based 18 | response column names, another for the Question Text stem and choice text (although 19 | truncated), and a row with QID based column names.} 20 | } 21 | \value{ 22 | a table with the matrix-sub-questions listed 23 | in the first column, the percentages for each 24 | choice for each sub-question listed in a table, and 25 | then another column with the total respondents 26 | for each subquestion. 27 | } 28 | \description{ 29 | The matrix_single_answer_results function uses the 30 | definition of the choices and answers in the 31 | QSF file and their potentially recoded values to 32 | determine how to table the results paired 33 | to that question. If you look at the source code, 34 | keep in mind that a matrix question's sub-questions 35 | are called "Choices" and that the choices for each 36 | sub-question are called "Answers" 37 | } 38 | -------------------------------------------------------------------------------- /man/mc_multiple_answer_results.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{mc_multiple_answer_results} 4 | \alias{mc_multiple_answer_results} 5 | \title{Create the Results Table for a Multiple Choice Single Answer Question} 6 | \usage{ 7 | mc_multiple_answer_results(question, original_first_rows) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. The question must have a paired 12 | response column placed into the question 13 | under [['Responses']]. The insertion of the responses into questions is 14 | handled by link_responses_to_questions.} 15 | 16 | \item{original_first_rows}{A dataframe contianing the header information 17 | for each column of response data. This dataframe includes a row for the DataExportTag based 18 | response column names, another for the Question Text stem and choice text (although 19 | truncated), and a row with QID based column names.} 20 | } 21 | \description{ 22 | The mc_multiple_answer_results function uses the definition of the choices in the QSF file 23 | and their (if present) recoded values to determine how to table the results paired to that question. 24 | } 25 | -------------------------------------------------------------------------------- /man/mc_single_answer_results.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{mc_single_answer_results} 4 | \alias{mc_single_answer_results} 5 | \title{Create the Results Table for a Multiple Choice Single Answer Question} 6 | \usage{ 7 | mc_single_answer_results(question, original_first_rows) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. The question must have a paired 12 | response column placed into the question 13 | under [['Responses']]. The insertion of the responses into questions is 14 | handled by link_responses_to_questions.} 15 | 16 | \item{original_first_rows}{A dataframe contianing the header information 17 | for each column of response data. This dataframe includes a row for the DataExportTag based 18 | response column names, another for the Question Text stem and choice text (although 19 | truncated), and a row with QID based column names.} 20 | } 21 | \value{ 22 | A table with an N, Percent, and an unlabeled column 23 | containing the question's chocies. In the N and Percent columns 24 | the frequency statistics are computed for the question 25 | choice. 26 | } 27 | \description{ 28 | The mc_single_answer_results function uses the definition of the choices in the QSF file 29 | and their potentially recoded values to determine how to table the results paired to that question. 30 | } 31 | -------------------------------------------------------------------------------- /man/merge_split_column_into_comment_sheet.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/comment_coding.R 3 | \name{merge_split_column_into_comment_sheet} 4 | \alias{merge_split_column_into_comment_sheet} 5 | \title{Merge a Splitting Column into an Unprocessed Coded Comment Sheet} 6 | \usage{ 7 | merge_split_column_into_comment_sheet(coded_comment_sheet, responses, 8 | split_column) 9 | } 10 | \arguments{ 11 | \item{coded_comment_sheet}{A single dataframe, imported from a 12 | file in the format as specified by the wiki. 13 | https://github.com/ctesta01/QualtricsTools/wiki/Comment-Coding} 14 | 15 | \item{responses}{A dataframe of Qualtrics responses to a survey. 16 | Use ask_for_csv() to create such a dataframe from a CSV file.} 17 | 18 | \item{split_column}{The string name of the column to merge in for splitting} 19 | } 20 | \value{ 21 | A dataframe similar to the input coded_comment_sheet, but with 22 | the additional column specified by split_column merged in. 23 | } 24 | \description{ 25 | Run create_merged_response_column() before this to 26 | create the splitting column in the responses. 27 | Then pass the column name of the column created by 28 | create_merged_response_column() as split_column 29 | } 30 | -------------------------------------------------------------------------------- /man/notes_from_survey.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{notes_from_survey} 4 | \alias{notes_from_survey} 5 | \title{Generate a List of Notes Blocks} 6 | \usage{ 7 | notes_from_survey(survey) 8 | } 9 | \arguments{ 10 | \item{survey}{A qualtrics survey list object, 11 | uploaded from a Qualtrics Survey File (QSF). Use 12 | ask_for_qsf() to create such a survey list object from a QSF file.} 13 | } 14 | \value{ 15 | This returns a list of blocks with element type "NT" 16 | } 17 | \description{ 18 | Generate a List of Notes Blocks 19 | } 20 | -------------------------------------------------------------------------------- /man/number_of_blocks.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{number_of_blocks} 4 | \alias{number_of_blocks} 5 | \title{Count the Number of Blocks} 6 | \usage{ 7 | number_of_blocks(blocks) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of blocks} 11 | } 12 | \value{ 13 | the number of question blocks 14 | } 15 | \description{ 16 | Since the blocks list is used to transport some additional information 17 | beyond the contents of the survey questions, this function is here to 18 | help in counting how many valid question blocks there are. 19 | Any real question blocks will be enumerated (aka numbered) in R, as opposed to the 20 | content that's been added which will be named (with a string). This means that when 21 | looking at the names of the blocks list, the integer values or the values which 22 | have no name are the question blocks, and the values which have names are the 23 | information added by the QualtricsTools functions. This function counts up the former. 24 | } 25 | -------------------------------------------------------------------------------- /man/percent0.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{percent0} 4 | \alias{percent0} 5 | \title{Format a Numeric as a String Percentage 6 | This function formats a decimal number into a string percentage with 7 | a specific number of decimal places and with a "%" character. 8 | The function uses formatC from the R base package and 9 | defaults to formatting the number with 1 digit and with the "f" format 10 | in the formatC argument. 11 | This function is originally from the StackOverflow post: 12 | http://stackoverflow.com/questions/12688717/round-up-from-5-in-r} 13 | \usage{ 14 | percent0(x, digits = 1, format = "f", ...) 15 | } 16 | \description{ 17 | Format a Numeric as a String Percentage 18 | This function formats a decimal number into a string percentage with 19 | a specific number of decimal places and with a "%" character. 20 | The function uses formatC from the R base package and 21 | defaults to formatting the number with 1 digit and with the "f" format 22 | in the formatC argument. 23 | This function is originally from the StackOverflow post: 24 | http://stackoverflow.com/questions/12688717/round-up-from-5-in-r 25 | } 26 | -------------------------------------------------------------------------------- /man/process_question_results.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{process_question_results} 4 | \alias{process_question_results} 5 | \title{Append the Response Frequency Table to a Question} 6 | \usage{ 7 | process_question_results(question, original_first_rows) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. The question must have a paired 12 | response column placed into the question 13 | under [['Responses']]. The insertion of the responses into questions is 14 | handled by link_responses_to_questions.} 15 | 16 | \item{original_first_rows}{A dataframe contianing the header information 17 | for each column of response data. This dataframe includes a row for the DataExportTag based 18 | response column names, another for the Question Text stem and choice text (although 19 | truncated), and a row with QID based column names.} 20 | } 21 | \description{ 22 | This function uses the contents of a question to 23 | determine which kind of question the given question is. 24 | Then it passes the question and the original_first_rows 25 | to the function which processes questions of that specific 26 | question type. After adding the results `Table` to the question, 27 | the question is returned including this table as an additional new 28 | list element. 29 | } 30 | -------------------------------------------------------------------------------- /man/question_description.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{question_description} 4 | \alias{question_description} 5 | \title{Create Question Description and Results Table Entry} 6 | \usage{ 7 | question_description(question) 8 | } 9 | \arguments{ 10 | \item{question}{A qualtrics survey question} 11 | } 12 | \value{ 13 | A list of HTML with a description table for the question, 14 | and either the generated results, or a note saying why there are 15 | no results. 16 | } 17 | \description{ 18 | Create Question Description and Results Table Entry 19 | } 20 | -------------------------------------------------------------------------------- /man/question_from_response_column.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{question_from_response_column} 4 | \alias{question_from_response_column} 5 | \title{Get the Index of the Question Corresponding to a Response Column} 6 | \usage{ 7 | question_from_response_column(blocks, response_name) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of the survey blocks, with the questions and responses inserted 11 | in place of the BlockElements. Structuring the blocks in this way is automatically 12 | handled by get_reorganized_questions_and_blocks, but can also be performed by (after 13 | inserting the responses into questions) using the questions_into_blocks method.} 14 | 15 | \item{response_name}{The string name of a column from a Qualtrics response dataset.} 16 | } 17 | \value{ 18 | A pair, (i, j) which specifies a question as blocks[[i]][['BlockElements']][[j]]. 19 | } 20 | \description{ 21 | Use this function to get the location of a question 22 | in the blocks list. Give it a response column name, and it will 23 | try to find the question it corresponds to. Otherwise, it will 24 | error. The blocks have two layers of indexing, one for the individual 25 | blocks, and then another for the BlockElements. This function will return a 26 | pair of indices, (i, j) where blocks[[i]][['BlockElements']][[j]] specifies the 27 | location of the question which has the response_name column among its linked responses. 28 | } 29 | \details{ 30 | This function uses a primitive caching system to store a lookup table from the 31 | response column names to the pairs of block and block element indices in the 32 | package's environment, and recall it when the blocks have not changed between 33 | the construction of the lookup table and the current recent function call. 34 | The caching system uses a hash of the blocks, a string associated to 35 | the blocks such that if the blocks passed in are different, the hash of the 36 | blocks will be different, in order to tell when the blocks have changed. 37 | When the hash of the blocks passed as an argument match the hash stored in 38 | the cached lookup table, the cached lookup table is used. Otherwise, it is 39 | computed again and the lookup table in the environment is updated. 40 | } 41 | -------------------------------------------------------------------------------- /man/question_variable_to_choice_text.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{question_variable_to_choice_text} 4 | \alias{question_variable_to_choice_text} 5 | \title{Convert the Variable Response into its Corresponding Text} 6 | \usage{ 7 | question_variable_to_choice_text(question, choice, use_recode_values) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. A question must have the 'Choices' list 12 | inside its 'Payload' in order to be accepted by this function. Furthermore, 13 | the choice provided must appear in the Choices list (or if use_recode_values is 14 | TRUE then the choice argument provided must appear among the RecodeValues list).} 15 | 16 | \item{choice}{A choice response to a question, given as a string or number.} 17 | 18 | \item{use_recode_values}{A logical boolean value indicating whether or not the 19 | RecodeValues list needs to be used as an intermediary step in looking up the 20 | text corresponding to the passed choice argument.} 21 | } 22 | \value{ 23 | The text corresponding to the variable choice indicated for the given question. 24 | } 25 | \description{ 26 | This function looks up a choice's corresponding text 27 | by using the question[['Payload']][['Choice']] list, and if applicable, 28 | the question[['Payload']][['RecodeValues']] list as an intermediary lookup. 29 | Moreover, if a choice has a corresponding text entry component, this function 30 | attempts to identify which column corresponds to the text entry responses 31 | and modifies the returned choice text to include "See Appendix [Column DataExportTag]" 32 | where the [Column DataExportTag] is replaced by the column name of the corresponding 33 | text entry response column. 34 | } 35 | -------------------------------------------------------------------------------- /man/questions_from_blocks.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{questions_from_blocks} 4 | \alias{questions_from_blocks} 5 | \title{Generate a List of Questions from Those Contained in the Blocks} 6 | \usage{ 7 | questions_from_blocks(blocks) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of the survey blocks, with the questions and responses inserted 11 | in place of the BlockElements. Structuring the blocks in this way is automatically 12 | handled by get_reorganized_questions_and_blocks, but can also be performed by (after 13 | inserting the responses into questions) using the questions_into_blocks method.} 14 | } 15 | \description{ 16 | This function iterates through the blocks and anything that has a DataExportTag 17 | is added to a list of questions, and it returns that list of questions from 18 | the blocks. 19 | } 20 | -------------------------------------------------------------------------------- /man/questions_from_survey.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{questions_from_survey} 4 | \alias{questions_from_survey} 5 | \title{Generate a List of Questions} 6 | \usage{ 7 | questions_from_survey(survey) 8 | } 9 | \arguments{ 10 | \item{survey}{A qualtrics survey list object, 11 | uploaded from a Qualtrics Survey File (QSF). Use 12 | ask_for_qsf() to create such a survey list object from a QSF file.} 13 | } 14 | \value{ 15 | A list of questions from the uploaded QSF file 16 | } 17 | \description{ 18 | This function takes the questions out of the survey and 19 | turns them into their own list for later use. 20 | Each question is an element of the returned list, and 21 | each element has its own list as its content. Most questions 22 | include things like "SurveyID", "Element", "PrimaryAttribute", 23 | "SecondaryAttribute", and a "Payload" which contains 24 | most of the information about the question. 25 | } 26 | -------------------------------------------------------------------------------- /man/questions_into_blocks.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{questions_into_blocks} 4 | \alias{questions_into_blocks} 5 | \title{Organize the Questions into their Survey Blocks} 6 | \usage{ 7 | questions_into_blocks(questions, blocks) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a Qualtrics survey} 11 | 12 | \item{blocks}{A list of blocks from a Qualtrics survey} 13 | } 14 | \value{ 15 | a list of blocks including questions under blocks[[i]][['BlockElements']] 16 | for each index i. 17 | } 18 | \description{ 19 | This function takes a blocks list (create this with blocks_from_survey and 20 | then remove_trash_blocks), inserts the questions from a survey 21 | appropriately into the blocks element, and then returns the 22 | blocks list including the questions as elements in the blocks[[i]][['BlockElements']]. 23 | } 24 | -------------------------------------------------------------------------------- /man/remove_trash_blocks.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{remove_trash_blocks} 4 | \alias{remove_trash_blocks} 5 | \title{Remove the Trash Block from the list of Blocks} 6 | \usage{ 7 | remove_trash_blocks(blocks) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of blocks from a Qualtrics survey} 11 | } 12 | \value{ 13 | The list of blocks is returned without any Trash blocks 14 | } 15 | \description{ 16 | This function finds among the trash blocks which has its [['Type']] value 17 | set to "Trash" and then removes it from the blocks list. The iteration 18 | in this function is backwards because it assigns NULL to any list 19 | items which need to be removed. Therefore, if it assigns NULL 20 | to a value and then moves up, it will not only skip questions as the 21 | higher up questions move downward as questions are deleted, but 22 | the total length of the list will be changing as it gets closer to the 23 | end of the list. 24 | } 25 | -------------------------------------------------------------------------------- /man/remove_trash_questions.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{remove_trash_questions} 4 | \alias{remove_trash_questions} 5 | \title{Remove Questions from the Trash Block} 6 | \usage{ 7 | remove_trash_questions(questions, blocks) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a Qualtrics survey} 11 | 12 | \item{blocks}{A list of blocks from a Qualtrics survey} 13 | } 14 | \value{ 15 | The list of questions returned is the list of questions 16 | provided except without any questions listed in the Trash 17 | block of the blocks list provided. 18 | } 19 | \description{ 20 | This function removes any questions from a list of questions 21 | that are listed in the Trash block. 22 | } 23 | -------------------------------------------------------------------------------- /man/repath.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/helper_functions.R 3 | \name{repath} 4 | \alias{repath} 5 | \title{Repath Windows Paths with "\" to ones with "/" 6 | This function is originally from a StackOverflow comment here: 7 | https://stackoverflow.com/questions/1189759/expert-r-users-whats-in-your-rprofile/12703931#12703931} 8 | \usage{ 9 | repath() 10 | } 11 | \description{ 12 | Repath Windows Paths with "\" to ones with "/" 13 | This function is originally from a StackOverflow comment here: 14 | https://stackoverflow.com/questions/1189759/expert-r-users-whats-in-your-rprofile/12703931#12703931 15 | } 16 | -------------------------------------------------------------------------------- /man/sample_responses.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/data.R 3 | \docType{data} 4 | \name{sample_responses} 5 | \alias{sample_responses} 6 | \title{Sample Qualtrics Response Data} 7 | \format{An object of class \code{data.frame} with 10 rows and 38 columns.} 8 | \usage{ 9 | sample_responses 10 | } 11 | \description{ 12 | This is some sample response data, to the matching sample survey provided 13 | } 14 | \keyword{datasets} 15 | -------------------------------------------------------------------------------- /man/sample_survey.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/data.R 3 | \docType{data} 4 | \name{sample_survey} 5 | \alias{sample_survey} 6 | \title{Sample Qualtrics Survey Data} 7 | \format{An object of class \code{list} of length 2.} 8 | \usage{ 9 | sample_survey 10 | } 11 | \description{ 12 | This is a sample survey, with a couple questions of different types. 13 | } 14 | \keyword{datasets} 15 | -------------------------------------------------------------------------------- /man/split_respondents.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{split_respondents} 4 | \alias{split_respondents} 5 | \title{Split Respondents by a Response Column} 6 | \usage{ 7 | split_respondents(response_column, responses, survey, blocks, questions, 8 | headerrows, already_loaded, original_first_rows) 9 | } 10 | \arguments{ 11 | \item{response_column}{The response column that will be used to split the respondents} 12 | 13 | \item{responses}{A dataframe of Qualtrics responses to a survey. 14 | Use ask_for_csv() to create such a dataframe from a CSV file.} 15 | 16 | \item{survey}{A qualtrics survey list object, 17 | uploaded from a Qualtrics Survey File (QSF). Use 18 | ask_for_qsf() to create such a survey list object from a QSF file.} 19 | 20 | \item{blocks}{The blocks provided to this function must include questions inserted into 21 | the BlockElements. Create the list of blocks from a survey with blocks_from_survey(), 22 | and with questions on hand, insert them into the blocks with questions_into_blocks().} 23 | 24 | \item{already_loaded}{This can be set to TRUE to indicate that the survey and responses 25 | should be sourced from the global scope; in other words that the survey and its responses 26 | have are "already loaded."} 27 | 28 | \item{original_first_rows}{A dataframe contianing the header information 29 | for each column of response data. This dataframe includes a row for the DataExportTag based 30 | response column names, another for the Question Text stem and choice text (although 31 | truncated), and a row with QID based column names.} 32 | } 33 | \value{ 34 | A list of a list of blocks. The same question, but with different respondent groups, 35 | might look something like split_blocks[[1]][[1]][['BlockElements']][[1]] and 36 | split_blocks[[2]][[1]][['BlockElements']][[1]]. These refer to the first and second respondent 37 | groups, the first block, and the first block element. 38 | } 39 | \description{ 40 | This function splits the respondents into separate respondent groups 41 | based on the values in the specified response column. Then, for each 42 | respondent group, the blocks with questions are duplicated. Each set of 43 | blocks has a different responent group inserted into its questions, and 44 | then each set of blocks is processed. The output is a list of blocks with 45 | the results processed and inserted into each BlockElement. 46 | } 47 | -------------------------------------------------------------------------------- /man/split_side_by_sides.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{split_side_by_sides} 4 | \alias{split_side_by_sides} 5 | \title{Split Side-by-Side Questions into Multiple Questions} 6 | \usage{ 7 | split_side_by_sides(questions, blocks) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a survey} 11 | 12 | \item{blocks}{A list of blocks from a survey} 13 | } 14 | \value{ 15 | A list of questions and a list of blocks with their SBS questions split 16 | into multiple questions 17 | } 18 | \description{ 19 | This function updates both the list of questions and list of blocks from a survey 20 | to reflect a side-by-side question as multiple individual questions. 21 | } 22 | -------------------------------------------------------------------------------- /man/tabelize_display_logic.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{tabelize_display_logic} 4 | \alias{tabelize_display_logic} 5 | \title{Generate Tables for Each Question with Display Logic} 6 | \usage{ 7 | tabelize_display_logic(blocks, flow) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of the survey blocks, with the questions included in them.} 11 | 12 | \item{flow}{A list of strings identifying the blocks in the order that they appear 13 | within the survey.} 14 | } 15 | \value{ 16 | a list of html tables detailing the display logic for each question 17 | containing display logic. 18 | } 19 | \description{ 20 | This function loops through every block, and checks if 21 | each block element has display logic (and is not a descriptive box). 22 | The descriptive boxes aren't included. 23 | If it has display logic, it's inserted into the tables returned by 24 | this function. 25 | } 26 | -------------------------------------------------------------------------------- /man/table_html_coded_comments.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{table_html_coded_comments} 4 | \alias{table_html_coded_comments} 5 | \title{Create a Text Appendix for Coded Comments} 6 | \usage{ 7 | table_html_coded_comments(question, cc_index, appendix_e, blocks, 8 | original_first_row) 9 | } 10 | \arguments{ 11 | \item{question}{is the question to which the coded comments belong.} 12 | 13 | \item{cc_index}{is the index of the coded comments to appendicize.} 14 | 15 | \item{appendix_e}{is the number of the appendix in the text appendices report.} 16 | 17 | \item{blocks}{is the list of survey blocks.} 18 | 19 | \item{original_first_row}{is the original header information from the CSV response data.} 20 | } 21 | \description{ 22 | This returns a list containing two tables: the question's description table and the categorical 23 | breakdown of the responses into the coded comments' categories. The description includes an 24 | "Appendix ##" title, the question text, and a tag which states the following appendix is 25 | "Coded Comments." The coded comments table has two columns: the "Responses" and "N", in which 26 | the categories and their frequencies are listed. 27 | } 28 | -------------------------------------------------------------------------------- /man/table_mcsa_multitext.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{table_mcsa_multitext} 4 | \alias{table_mcsa_multitext} 5 | \title{Create a message stating MCSA questions with Multiple Text Entry components 6 | can't be automatically processed for text appendices.} 7 | \usage{ 8 | table_mcsa_multitext(question) 9 | } 10 | \arguments{ 11 | \item{question}{A qualtrics survey question} 12 | } 13 | \description{ 14 | Create a message stating MCSA questions with Multiple Text Entry components 15 | can't be automatically processed for text appendices. 16 | } 17 | -------------------------------------------------------------------------------- /man/table_no_respondents.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{table_no_respondents} 4 | \alias{table_no_respondents} 5 | \title{Create a standard "No Respondents answered this question" text appendix} 6 | \usage{ 7 | table_no_respondents(question, appendix_e) 8 | } 9 | \arguments{ 10 | \item{question}{is the question for which the text appendix is being created.} 11 | 12 | \item{appendix_e}{is the number of the appendix in the text appendices report.} 13 | } 14 | \description{ 15 | This function returns a standardized html table intended to go into a 16 | document of text appendices indicating that there were no respondents 17 | who answered the given text entry question. 18 | } 19 | -------------------------------------------------------------------------------- /man/table_non_text_entry.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{table_non_text_entry} 4 | \alias{table_non_text_entry} 5 | \title{Create Text Appendices for Non-Text Entry Type Questions} 6 | \usage{ 7 | table_non_text_entry(question, text_responses, appendix_e, blocks, 8 | original_first_row) 9 | } 10 | \arguments{ 11 | \item{question}{is the question for which the text appendix is being created.} 12 | 13 | \item{appendix_e}{is the number of the appendix in the text appendices report.} 14 | 15 | \item{blocks}{A list of blocks with block elements replaced 16 | by the question with its paired responses.} 17 | 18 | \item{responses}{is a data frame of text responses to the question given.} 19 | } 20 | \description{ 21 | This function creates text appendices, with a description table and 22 | responses table, for questions which are not text-entry type questions. 23 | The description table contains a text appendix title, like "Appendix A" 24 | and the responses are tabled verbatim beneath it. 25 | } 26 | -------------------------------------------------------------------------------- /man/table_text_entry.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{table_text_entry} 4 | \alias{table_text_entry} 5 | \title{Create Text Appendices for Text Entry Type Questions} 6 | \usage{ 7 | table_text_entry(question, text_responses, appendix_e, blocks, 8 | original_first_row) 9 | } 10 | \arguments{ 11 | \item{question}{is the question for which the text appendix is being created.} 12 | 13 | \item{appendix_e}{is the number of the appendix in the text appendices report.} 14 | 15 | \item{blocks}{is the list of survey blocks.} 16 | 17 | \item{original_first_row}{is the original header information from the CSV response data.} 18 | 19 | \item{responses}{is a data frame of text responses to the question given.} 20 | } 21 | \description{ 22 | The `table_text_entry` function creates a text appendix with as many 23 | columns as there are text entry components to the given question and fills 24 | them with the responses from each respondent across the rows. 25 | } 26 | -------------------------------------------------------------------------------- /man/text_appendices_table.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{text_appendices_table} 4 | \alias{text_appendices_table} 5 | \title{Create HTML Tables for the Text Entry Questions} 6 | \usage{ 7 | text_appendices_table(blocks, original_first_rows, flow, n_threshold = 15) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of blocks with block elements replaced 11 | by the question with its paired responses.} 12 | 13 | \item{original_first_rows}{This is the original first row of the 14 | response set. If you have the original_first_rowss, you can 15 | pass original_first_rowss[1,] to} 16 | 17 | \item{flow}{is a list of blockIDs which is used to order the questions 18 | in the output report.} 19 | 20 | \item{n_threshold}{is the number of comments which must be present in order 21 | for a coded comments table to appear.} 22 | } 23 | \value{ 24 | an html string containing a title, 25 | question text, and the text responses for each 26 | text appendix. 27 | } 28 | \description{ 29 | This function creates an HTML string with tables 30 | for each of the text entry questions and their text_responses. 31 | The appendix_lettering function inside this function 32 | is to create lettering for the tables in the style 33 | of "A, B, ..., Z, AA, ..., ZZ" and so forth. The html 34 | tables are created by looping through the blocks 35 | and their contained question block elements. For each 36 | question, if the question is a Text Entry question or 37 | any of the response columns contain "TEXT" then a table 38 | is created for those text_responses. 39 | } 40 | -------------------------------------------------------------------------------- /man/uncodeable_question_dictionary.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/reorganizing_survey_data.R 3 | \name{uncodeable_question_dictionary} 4 | \alias{uncodeable_question_dictionary} 5 | \title{Create Uncodeable Question Dictionary} 6 | \usage{ 7 | uncodeable_question_dictionary(blocks) 8 | } 9 | \arguments{ 10 | \item{blocks}{A list of blocks with questions that have been 11 | processed with generate_results(questions). The questions can be inserted 12 | into the blocks from a survey by using questions_into_blocks(questions, blocks).} 13 | } 14 | \value{ 15 | A data frame providing the details of the questions that were not 16 | successfully processed by generate_results(questions). 17 | } 18 | \description{ 19 | The "uncodeable" questions are the questions that 20 | do not have results tables inserted into them. This 21 | function is meant to run on a list of blocks that have 22 | had questions with their results tables inserted into them. 23 | For any that do not have results tables, this function 24 | assumes they were not successfully processed, adds them to the 25 | list of uncodeable questions, and then returns a 26 | question dictionary detailing them. 27 | } 28 | -------------------------------------------------------------------------------- /man/uncodeable_questions_message.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/html_results.R 3 | \name{uncodeable_questions_message} 4 | \alias{uncodeable_questions_message} 5 | \title{Create a Message Stating Which Questions Weren't Automatically Tabled} 6 | \usage{ 7 | uncodeable_questions_message(questions) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a survey with results inserted into them.} 11 | } 12 | \value{ 13 | A message stating for which questions could not have 14 | results automatically generated. 15 | } 16 | \description{ 17 | This is function is used in the Shiny app to tell users which questions weren't 18 | automatically coded. This may be changed later to be more informative, or 19 | to include this information elsewhere. 20 | } 21 | -------------------------------------------------------------------------------- /man/validate_data_export_tags.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/loading_files.R 3 | \name{validate_data_export_tags} 4 | \alias{validate_data_export_tags} 5 | \title{Validate Data Export Tag Uniqueness} 6 | \usage{ 7 | validate_data_export_tags(questions) 8 | } 9 | \arguments{ 10 | \item{questions}{A list of questions from a Qualtrics survey} 11 | } 12 | \description{ 13 | It is crucial for parts of this program to work that the DataExportTags be unique 14 | to one another. This program checks for duplicates among the DataExportTags, and 15 | returns a boolean statement representing whether or not the DataExportTags validated. 16 | validate_export_tags returns TRUE if the DataExportTags are not duplicated, and are valid, 17 | and FALSE if the DataExportTags did not validate, and are duplicated. 18 | } 19 | -------------------------------------------------------------------------------- /man/which_choices_have_text_entry.Rd: -------------------------------------------------------------------------------- 1 | % Generated by roxygen2: do not edit by hand 2 | % Please edit documentation in R/results_generation.R 3 | \name{which_choices_have_text_entry} 4 | \alias{which_choices_have_text_entry} 5 | \title{Find out Which Choices Have Text Entry Components} 6 | \usage{ 7 | which_choices_have_text_entry(question) 8 | } 9 | \arguments{ 10 | \item{question}{This is a list object representing an individual question 11 | from a Qualtrics Survey File. A question must have the 'Choices' list 12 | inside its 'Payload' in order to be accepted by this function.} 13 | } 14 | \value{ 15 | A list of the indices for the choices which have a text entry component. 16 | } 17 | \description{ 18 | Given a single question, this function 19 | determines which of the question[['Payload']][['Choices']] 20 | elements have a TextEntry which is enabled for free response 21 | input. The returned value is a list of integers representing 22 | the indices of which choices have text entry components. 23 | } 24 | -------------------------------------------------------------------------------- /pics/animation.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/pics/animation.gif -------------------------------------------------------------------------------- /pics/display logic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/pics/display logic.png -------------------------------------------------------------------------------- /pics/include exclude questions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/pics/include exclude questions.png -------------------------------------------------------------------------------- /pics/more options.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/pics/more options.png -------------------------------------------------------------------------------- /pics/question dictionary.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/pics/question dictionary.png -------------------------------------------------------------------------------- /pics/results tables.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/pics/results tables.png -------------------------------------------------------------------------------- /pics/text appendices.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ctesta01/QualtricsTools/8baa7cc31349b6f83189c21d2104988d31e656bc/pics/text appendices.png -------------------------------------------------------------------------------- /tests/testthat.R: -------------------------------------------------------------------------------- 1 | library(testthat) 2 | library(QualtricsTools) 3 | 4 | test_check("QualtricsTools") 5 | -------------------------------------------------------------------------------- /tests/testthat/test_comment_coding.R: -------------------------------------------------------------------------------- 1 | library(QualtricsTools) 2 | library(XML) 3 | 4 | context("Generating text appendices with inserted coded comments") 5 | 6 | surveysdir = file.path(path.package('QualtricsTools'), 'data/Sample Surveys/') 7 | 8 | test_that("Test that make_coded_comments includes the categories defined in the coded comments.", { 9 | 10 | requireNamespace("XML") 11 | 12 | # This test replicates the contents of the make_coded_comments function. 13 | # It tests several 14 | 15 | qsf_path = file.path(surveysdir, "/Better Sample Survey/Better_Sample_Survey.qsf") 16 | csv_path = file.path(surveysdir, "/Better Sample Survey/Better_Sample_Survey.csv") 17 | sheets_dir = file.path(surveysdir, "/Comment Coding/Coded Comments/") 18 | # output_file <- make_coded_comments( 19 | # qsf_path = qsf, 20 | # csv_path = csv, 21 | # headerrows = 3, 22 | # sheets_dir = sheets_dir, 23 | # n_threshold = 0) 24 | 25 | headerrows <- 3 26 | get_setup_in_environment( 27 | qsf_path = qsf_path, 28 | csv_path = csv_path, 29 | headerrows = headerrows, 30 | environment = environment() 31 | ) 32 | 33 | coded_sheets <- directory_get_coded_comment_sheets(sheets_dir) 34 | 35 | if (is.null(coded_sheets)) { 36 | stop("Please fix errors before attempting again") 37 | } 38 | 39 | comment_tables <- 40 | format_coded_comment_sheets(coded_comment_sheets = coded_sheets) 41 | blocks <- 42 | insert_coded_comments( 43 | blocks = blocks, 44 | original_first_rows = original_first_rows, 45 | coded_comments = comment_tables 46 | ) 47 | 48 | # Used with html_2_pandoc below to keeps the flow of the survey consistent with the output 49 | flow = flow_from_survey(survey) 50 | 51 | output_html <- c( 52 | blocks_header_to_html(blocks), 53 | text_appendices_table( 54 | blocks = blocks, 55 | original_first_row = original_first_rows, 56 | flow = flow, 57 | n_threshold = 0 58 | ) 59 | ) 60 | 61 | output_file <- html_2_pandoc( 62 | html = output_html 63 | ) 64 | 65 | # Ensure that files are being output. 66 | expect_true(file.exists(output_file)) 67 | html_tables <- XML::readHTMLTable(output_html) 68 | # Ensure that there is contents being output into the file. 69 | expect_true(length(html_tables) > 0) 70 | times_appendix_A_appears <- 71 | which(as.logical(lapply(unlist(html_tables), function(x) grepl("Appendix A", x)))) 72 | # Since these are coded comments, make sure that there are multiple 73 | # Appendix A entries when unlisting the contents of the HTML. 74 | expect_true(length(times_appendix_A_appears) >= 2) 75 | }) 76 | 77 | -------------------------------------------------------------------------------- /tests/testthat/test_reorganizing_survey_data.R: -------------------------------------------------------------------------------- 1 | library(QualtricsTools) 2 | 3 | context("Testing for correct structure in the output of functions from reorganizing_survey_data.R") 4 | 5 | surveysdir = file.path(path.package('QualtricsTools'), 'data/Sample Surveys/') 6 | 7 | test_that("Test that blocks_from_survey returns a list with elements which each have a Type, Description, and ID", { 8 | qsf_path = file.path(surveysdir, "/Better Sample Survey/Better_Sample_Survey.qsf") 9 | headerrows <- 3 10 | survey <- ask_for_qsf(qsf_path) 11 | blocks <- blocks_from_survey(survey) 12 | all_blocks_contain_type <- all(sapply(blocks, function(x) "Type" %in% names(x))) 13 | all_blocks_contain_ID <- all(sapply(blocks, function(x) "ID" %in% names(x))) 14 | all_blocks_contain_description <- all(sapply(blocks, function(x) "Description" %in% names(x))) 15 | expect_true(all(c(all_blocks_contain_ID, all_blocks_contain_type, all_blocks_contain_description))) 16 | }) 17 | 18 | 19 | test_that("Notes are inserted into questions by insert_notes_into_questions", { 20 | qsf_path <- file.path(surveysdir, "User Notes Survey/Notes_Survey.qsf") 21 | survey <- ask_for_qsf(qsf_path) 22 | blocks <- blocks_from_survey(survey) 23 | # insert_notes_into_questions is performed by get_reorganized_questions_and_blocks 24 | questions_and_blocks <- get_reorganized_questions_and_blocks(survey=survey, responses=data.frame(), original_first_rows=data.frame()) 25 | questions <- questions_and_blocks[[1]] 26 | # Test that there exist qtNotes with "User Note" inserted into them. 27 | user_notes_exist_in_questions <- 28 | length(which(sapply(questions, function(x) { 29 | 'qtNotes' %in% names(x) && 30 | grepl("User Note", x[['qtNotes']]) 31 | }))) > 0 32 | expect_true(user_notes_exist_in_questions) 33 | }) 34 | 35 | 36 | -------------------------------------------------------------------------------- /tests/testthat/test_results_reports.R: -------------------------------------------------------------------------------- 1 | # Test generate_results_tables 2 | 3 | context("Generating generate_results_tables on Sample Surveys") 4 | surveysdir = file.path(path.package('QualtricsTools'), 'data/Sample Surveys/') 5 | 6 | test_that("Test that generate_results_tables creates a file when run on the Better Sample Survey", { 7 | survey_dir = file.path(surveysdir, "Better Sample Survey") 8 | qsf = file.path(survey_dir, "Better_Sample_Survey.qsf") 9 | csv = file.path(survey_dir, "Better_Sample_Survey.csv") 10 | results_output_file = make_results_tables(headerrows=3, qsf_path = qsf, csv_path = csv) 11 | status = file.exists(results_output_file) 12 | expect_equal(status, TRUE) 13 | }) 14 | 15 | test_that("Test that generate_results_tables creates a file when run on the Long Exhaustive Sample Survey", { 16 | survey_dir = file.path(surveysdir, "Long Exhaustive Sample Survey") 17 | qsf = file.path(survey_dir, "Long_Exhaustive_Sample_Survey.qsf") 18 | csv = file.path(survey_dir, "Long_Exhaustive_Sample_Survey.csv") 19 | results_output_file = make_results_tables(headerrows=3, qsf_path = qsf, csv_path = csv) 20 | status = file.exists(results_output_file) 21 | expect_equal(status, TRUE) 22 | }) 23 | 24 | test_that("Test that generate_results_tables creates a file when run on the No Basis for Evaluation Survey", { 25 | survey_dir = file.path(surveysdir, "No Basis for Evaluation") 26 | qsf = file.path(survey_dir, "No_Basis_for_Evaluation.qsf") 27 | csv = file.path(survey_dir, "No_Basis_for_Evaluation (Insights).csv") 28 | results_output_file = make_results_tables(headerrows=3, qsf_path = qsf, csv_path = csv) 29 | status = file.exists(results_output_file) 30 | expect_equal(status, TRUE) 31 | }) 32 | 33 | test_that("Test that generate_results_tables creates a file when run on the Survey Logic Survey", { 34 | survey_dir = file.path(surveysdir, "Survey Logic") 35 | qsf = file.path(survey_dir, "Survey_Logic_EVERYWHERE.qsf") 36 | csv = file.path(survey_dir, "Survey_Logic_EVERYWHERE.csv") 37 | results_output_file = make_results_tables(headerrows=3, qsf_path = qsf, csv_path = csv) 38 | status = file.exists(results_output_file) 39 | expect_equal(status, TRUE) 40 | }) 41 | 42 | test_that("Test that generate_results_tables creates a file when run on the User Notes Survey", { 43 | survey_dir = file.path(surveysdir, "User Notes Survey") 44 | qsf = file.path(survey_dir, "Notes_Survey.qsf") 45 | csv = file.path(survey_dir, "Notes_Survey.csv") 46 | results_output_file = make_results_tables(headerrows=3, qsf_path = qsf, csv_path = csv) 47 | status = file.exists(results_output_file) 48 | expect_equal(status, TRUE) 49 | }) 50 | -------------------------------------------------------------------------------- /tests/testthat/test_text_appendices.R: -------------------------------------------------------------------------------- 1 | library(QualtricsTools) 2 | 3 | context("Generating generate_text_appendices on Sample Surveys") 4 | 5 | surveysdir = file.path(path.package('QualtricsTools'), 'data/Sample Surveys/') 6 | 7 | test_that("Test that generate_results_tables creates a file when run on the Better Sample Survey", { 8 | survey_dir = file.path(surveysdir, "Better Sample Survey") 9 | qsf = file.path(survey_dir, "Better_Sample_Survey.qsf") 10 | csv = file.path(survey_dir, "Better_Sample_Survey.csv") 11 | results_output_file = make_text_appendices(headerrows=3, qsf_path = qsf, csv_path = csv) 12 | status = file.exists(results_output_file) 13 | expect_true(status) 14 | }) 15 | 16 | test_that("Test that generate_results_tables creates a file when run on the Long Exhaustive Sample Survey", { 17 | survey_dir = file.path(surveysdir, "Long Exhaustive Sample Survey") 18 | qsf = file.path(survey_dir, "Long_Exhaustive_Sample_Survey.qsf") 19 | csv = file.path(survey_dir, "Long_Exhaustive_Sample_Survey.csv") 20 | results_output_file = make_text_appendices(headerrows=3, qsf_path = qsf, csv_path = csv) 21 | status = file.exists(results_output_file) 22 | expect_true(status) 23 | }) 24 | 25 | test_that("Test that generate_results_tables creates a file when run on the No Basis for Evaluation Survey", { 26 | survey_dir = file.path(surveysdir, "No Basis for Evaluation") 27 | qsf = file.path(survey_dir, "No_Basis_for_Evaluation.qsf") 28 | csv = file.path(survey_dir, "No_Basis_for_Evaluation (Insights).csv") 29 | results_output_file = make_text_appendices(headerrows=3, qsf_path = qsf, csv_path = csv) 30 | status = file.exists(results_output_file) 31 | expect_true(status) 32 | }) 33 | 34 | test_that("Test that generate_results_tables creates a file when run on the Survey Logic Survey", { 35 | survey_dir = file.path(surveysdir, "Survey Logic") 36 | qsf = file.path(survey_dir, "Survey_Logic_EVERYWHERE.qsf") 37 | csv = file.path(survey_dir, "Survey_Logic_EVERYWHERE.csv") 38 | results_output_file = make_text_appendices(headerrows=3, qsf_path = qsf, csv_path = csv) 39 | status = file.exists(results_output_file) 40 | expect_true(status) 41 | }) 42 | 43 | test_that("Test that generate_results_tables creates a file when run on the User Notes Survey", { 44 | survey_dir = file.path(surveysdir, "User Notes Survey") 45 | qsf = file.path(survey_dir, "Notes_Survey.qsf") 46 | csv = file.path(survey_dir, "Notes_Survey.csv") 47 | results_output_file = make_text_appendices(headerrows=3, qsf_path = qsf, csv_path = csv) 48 | status = file.exists(results_output_file) 49 | expect_true(status) 50 | }) 51 | -------------------------------------------------------------------------------- /vignettes/Comment-Coding.Rmd: -------------------------------------------------------------------------------- 1 | --- 2 | title: Inserting Coded Comments into Output Text Appendices 3 | --- 4 | 5 | QualtricsTools not only makes it easy to create reports of text appendices, but 6 | also to create text appendices with frequency reports of categorized "coded comments." 7 | The coded comments must follow a standardized format, containing the "ResponseID" 8 | in the first column, and a column titled "varname" past which each column title 9 | represents a category which have "1" entries in cells to represent a respondent's 10 | response being categorized into the given category. 11 | 12 | An example of a coded comments document is included in the QualtricsTools package. 13 | In the prescribed workflow, each individual text entry component of a survey 14 | which needs to be categorized must have a corresponding coded comments xlsx file 15 | in a directory. However, in this example we will only use coded comments 16 | for a single text entry component. 17 | 18 | First, let's download the data into a directory. 19 | 20 | ```{r} 21 | library(shiny) 22 | library(QualtricsTools) 23 | library(RCurl) 24 | 25 | # Grab the sample survey data from our repository. 26 | qsf <- getURL("https://raw.githubusercontent.com/emmamorgan-tufts/QualtricsTools/master/data/Sample%20Surveys/Better%20Sample%20Survey/Better_Sample_Survey.qsf") 27 | csv <- getURL("https://raw.githubusercontent.com/emmamorgan-tufts/QualtricsTools/master/data/Sample%20Surveys/Better%20Sample%20Survey/Better_Sample_Survey.csv") 28 | 29 | # Write the sample survey data to file. 30 | qsf_tempfile_path = tempfile() 31 | csv_tempfile_path = tempfile() 32 | write(x = qsf, file = qsf_tempfile_path) 33 | write(x = csv, file = csv_tempfile_path) 34 | 35 | # Download the sample coded comments 36 | url <- "https://github.com/emmamorgan-tufts/QualtricsTools/blob/master/data/Sample%20Surveys/Comment%20Coding/Coded%20Comments/Q5%20Coded.xlsx?raw=true" 37 | coded_comments_directory <- file.path(tempdir(), basename(tempfile(pattern=""))) 38 | dir.create(path = coded_comments_directory) 39 | filename <- "Q5 Coded.xlsx" 40 | coded_comments_filepath <- file.path(coded_comments_directory, filename) 41 | download.file(url, coded_comments_filepath, mode="wb") 42 | ``` 43 | 44 | Just to make clear what the formatting of the Coded Comments should be, here's the file we just downloaded. 45 | ```{r} 46 | df <- readxl::read_xlsx(coded_comments_filepath) 47 | options(knitr.kable.NA = '') 48 | knitr::kable(df, format='markdown') 49 | ``` 50 | 51 | ```{r} 52 | output_filepath <- make_coded_comments( 53 | qsf_path = qsf_tempfile_path, 54 | csv_path = csv_tempfile_path, 55 | headerrows = 3, 56 | sheets_dir = coded_comments_directory, 57 | n_threshold = 0, 58 | filename = "ExampleHTMLCodedComments.html" 59 | ) 60 | ``` 61 | 62 | ```{r} 63 | # We use the includeHTML function from the shiny package to 64 | # render the HTML output. 65 | includeHTML(output_filepath) 66 | ``` 67 | 68 | 69 | The `n_threshold` parameter which is passed above as 0 is the threshold for which coded comments frequency tables with a total number of responses less than `n_threshold` are not included. The parameter defaults to 15 if it is not specified. For example, when we render the report with the `n_threshold = 15` default parameter we see that the coded comments frequency table is not included in the report: 70 | 71 | ```{r} 72 | output_filepath <- make_coded_comments( 73 | qsf_path = qsf_tempfile_path, 74 | csv_path = csv_tempfile_path, 75 | headerrows = 3, 76 | sheets_dir = coded_comments_directory, 77 | filename = "ExampleHTMLCodedComments.html" 78 | ) 79 | 80 | shiny::includeHTML(output_filepath) 81 | ``` 82 | -------------------------------------------------------------------------------- /vignettes/Finding-Undocumented-Parameters.Rmd: -------------------------------------------------------------------------------- 1 | --- 2 | title: Finding Undocumented Parameters 3 | author: Christian Testa 4 | date: July 2017 5 | vignette: > 6 | %\VignetteEngine{knitr::rmarkdown} 7 | %\VignetteIndexEntry{Finding Undocumented Parameters} 8 | %\usepackage[utf8]{inputenc} 9 | --- 10 | 11 | Let's try and find out what parameters are undocumented in my package QualtricsTools. 12 | 13 | This uses some internals (such as parse_rd and .Rd_get_argument_names) from the tools package 14 | with the .Rd files generated by Roxygen with the args function to get arguments of functions 15 | loaded from the QualtricsTools in order to approximately tell which parameters are undocumented 16 | in the package. 17 | 18 | The script below seems to be prone to false-positives where the documentation for a parameter does 19 | exist but the script lists the parameter as undocumented because the .Rd file is formatted unexpectedly 20 | or differently from usual. The documentation for some of these functions both exists and seems to 21 | render these false-positive parameters just fine, so this script is, for the moment, just a good way 22 | of finding what are likely candidates to be undocumented parameters. 23 | 24 | References 25 | 26 | - StackOverflow : [Get the list of functions loaded in R's global environment]( 27 | https://stackoverflow.com/questions/5103194/get-the-list-of-functions-loaded-in-rs-global-environment) 28 | - [Roxygen2 Manual]( 29 | http://roxygen.org/roxygen2-manual.pdf) 30 | 31 | ```{r} 32 | setwd("Q:/Student Work/Emma's Student Work/Report Generation/QualtricsTools/") 33 | devtools::load_all(".") 34 | library(tools) 35 | 36 | # List the Rd files from the QualtricsTools/man/ directory. 37 | # Get just the filename from each full file-path. 38 | # Then remove ".Rd" from the end. 39 | documentation_files <- list.files(file.path(path.package("QualtricsTools"), "man"), full.names = TRUE) 40 | documentation_files_basename <- lapply(documentation_files, basename) 41 | documentation_files_without_rd <- lapply(documentation_files_basename, function(x) gsub("*.Rd", "", x)) 42 | 43 | # Get the function names in the QualtricsTools package. 44 | function_names <- lsf.str(env=as.environment("package:QualtricsTools")) 45 | 46 | # Save messages output in this script into a list. 47 | output_messages <- list() 48 | 49 | # For each function in QualtricsTools... 50 | for (function_name in function_names) { 51 | # Check which documentation files match. 52 | corresponding_doc_file <- which(documentation_files_without_rd == function_name) 53 | # If there are none, print that there are no documentation files for that function. 54 | if (length(corresponding_doc_file) == 0) { 55 | output_list <- c(output_messages, paste0("There is no documentation file for ", function_name)) 56 | } else { 57 | # If there is a matching documentation file, check the first for its documented arguments 58 | # and compare with the function's arguments. 59 | corresponding_doc_file <- documentation_files[[corresponding_doc_file[[1]]]] 60 | documentation <- tools::parse_Rd(corresponding_doc_file) 61 | argument_names_from_documentation <- tools:::.Rd_get_argument_names(documentation) 62 | argument_names_from_function <- Filter(function(x) x != "", names(as.list(args(function_name)))) 63 | undocumented_parameters <- which(! argument_names_from_function %in% argument_names_from_documentation) 64 | if (length(undocumented_parameters) > 0) { 65 | output_messages <- c( 66 | output_messages, 67 | paste0(c( 68 | function_name, 69 | " has the following undocumented parameters: \n", 70 | paste0(argument_names_from_function[undocumented_parameters], 71 | collapse = "\n"), 72 | "\n\n" 73 | ), collapse = "")) 74 | } 75 | } 76 | } 77 | 78 | # Output to a temporary file 79 | output_file <- tempfile() 80 | write(x = paste0(output_messages, collapse="\n"), file = output_file) 81 | 82 | # And open the temporary file in Rstudio 83 | # file.edit(output_file) 84 | shiny::includeMarkdown(output_file) 85 | ``` 86 | -------------------------------------------------------------------------------- /vignettes/Generate-Results-Tables.Rmd: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Generating Results Tables" 3 | vignette: > 4 | %\VignetteEngine{knitr::rmarkdown} 5 | %\VignetteIndexEntry{Generating Results Tables} 6 | %\usepackage[utf8]{inputenc} 7 | --- 8 | 9 | The easiest way to create a report of frequency tables from a Qualtrics survey file and CSV response 10 | dataset is to use QualtricsTools' `make_results_tables` function. 11 | 12 | ```{r} 13 | library(QualtricsTools) 14 | # Let's use get_setup to load a sample survey. 15 | get_setup(sample_data=TRUE) 16 | # Using make_results_tables without definining the qsf_path or csv_path 17 | # parameters causes the function to retrieve the necessary survey data from 18 | # the global scope if all necessary objects are present. 19 | make_results_tables() 20 | ``` 21 | 22 | In this next example, I'm downloading a sample survey with responses as a 23 | QSF and CSV from the GitHub repository and then passing them 24 | as arguments to the make_results_tables function. 25 | 26 | ```{r} 27 | library(RCurl) 28 | 29 | # Grab the sample data from our repository. 30 | qsf <- getURL("https://raw.githubusercontent.com/emmamorgan-tufts/QualtricsTools/master/data/Sample%20Surveys/Better%20Sample%20Survey/Better_Sample_Survey.qsf") 31 | csv <- getURL("https://raw.githubusercontent.com/emmamorgan-tufts/QualtricsTools/master/data/Sample%20Surveys/Better%20Sample%20Survey/Better_Sample_Survey.csv") 32 | 33 | # Write the sample data to file. 34 | qsf_tempfile_path = tempfile() 35 | csv_tempfile_path = tempfile() 36 | write(x = qsf, file = qsf_tempfile_path) 37 | write(x = csv, file = csv_tempfile_path) 38 | 39 | make_results_tables( 40 | qsf_path = qsf_tempfile_path, 41 | csv_path = csv_tempfile_path, 42 | headerrows = 3 43 | ) 44 | ``` 45 | 46 | Of course, `make_results_tables` still does more than this. It allows users to specify their chosen output directory and desired output filename. In fact, `make_results_tables` automatically uses the file 47 | extension of the passed `filename` parameter to tell the `pandoc` program what format to convert the document into when rendering it. 48 | 49 | 50 | ```{r} 51 | output_filepath <- make_results_tables( 52 | qsf_path = qsf_tempfile_path, 53 | csv_path = csv_tempfile_path, 54 | headerrows = 3, 55 | output_dir = tempdir(), 56 | filename = "ExampleHTMLFile.html" 57 | ) 58 | 59 | requireNamespace("htmltools") 60 | htmltools::includeHTML(output_filepath) 61 | ``` 62 | 63 | -------------------------------------------------------------------------------- /vignettes/Recode-Values.Rmd: -------------------------------------------------------------------------------- 1 | --- 2 | title: An Introduction to Recode Values in Qualtrics 3 | vignette: > 4 | %\VignetteEngine{knitr::rmarkdown} 5 | %\VignetteIndexEntry{Recode Values} 6 | %\usepackage[utf8]{inputenc} 7 | --- 8 | 9 | # Using Recode Values in Qualtrics 10 | 11 | Recode Values are used for different purposes depending on the question 12 | type in the Qualtrics platform. Below is a quick reference to what kinds 13 | of variables are available to be defined by the user in a given question 14 | type, and where they appear in the response set. The Recode Values are 15 | always numeric variables, and Question Export Tags can be set as 16 | strings. On the following pages are short explanations for each question 17 | type with some screenshots of the recode values menu in use and the 18 | output the example creates. 19 | 20 | This guide covers the usage of recode values in the following question types: 21 | - Multiple Choice Single Answer 22 | - Multiple Choice Multiple Answer 23 | - Matrix Single Answer 24 | - Matrix Multiple Answer 25 | 26 | The following table describes where the recode values appear in the 27 | output responses datasets from Qualtrics depending on each question type. 28 | To make the below table a bit more tangible, following the table examples (with screenshots) are included of the recode values editor for 29 | each question type and how they appear in the output responses datasets. 30 | 31 | 32 | ```{r, echo=FALSE} 33 | html <- " 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 |
Question TypeVariables Available for UseWhere they Appear
Multiple Choice Single Answer Recode ValuesVariable Responses
Multiple Choice Multiple Answer  Recode ValuesResponse Column Names
Matrix Single AnswerRecode ValuesVariable Responses
Question Export TagsResponse Column Names
Matrix Multiple AnswerRecode ValuesResponse Column Names
Question Export TagsResponse Column Names
71 | " 72 | table_html_file <- tempfile() 73 | write(x = html, file = table_html_file) 74 | requireNamespace("shiny", quietly = TRUE) 75 | shiny::includeHTML(table_html_file) 76 | ``` 77 | 78 | 79 | 80 | 81 | ### Multiple Choice Single Answer Questions (Radio Buttons) 82 | 83 | In MCSA questions, the Recode Values are numerical values that will be 84 | used to assign variable values to each answer choice. 85 | 86 | #### Qualtrics Recode Values Editor 87 | ![](http://i.imgur.com/d1yYwCj.png) 88 | 89 | #### Recode Values' Appearance in Response Data 90 | ![](http://i.imgur.com/Put08IR.png) 91 | 92 | ### Multiple Choice Multiple Answer Questions (Check Boxes) 93 | 94 | In MCMA questions, the Recode Values are numerical values that will be 95 | appended to the data export tag (in this case "q3_volunteer") to label 96 | each response column. 97 | 98 | #### Qualtrics Recode Values Editor 99 | ![](http://i.imgur.com/Q1AGzns.png) 100 | 101 | #### Recode Values' Appearance in Response Data 102 | ![](http://i.imgur.com/kXx13oa.png) 103 | 104 | ### Likert Matrix Single Answer Questions 105 | 106 | There are two useful sections under the Recode Values menu for matrix 107 | questions: the Recode Values and the Question Export Tags. The Recode 108 | Values in a single answer matrix question are used to code the responses 109 | and the Question Export Tags are used (by appending them to the data 110 | export tag, in this case "q4_rank") to label the response columns. 111 | 112 | #### Qualtrics Recode Values Editor 113 | ![](http://i.imgur.com/FmVYnF9.png) 114 | 115 | #### Recode Values' Appearance in Response Data 116 | ![](http://i.imgur.com/2jxHkan.png) 117 | 118 | 119 | ### Likert Matrix Multiple Answer Questions 120 | 121 | In multiple answer matrix questions, both the Recode Values and the 122 | Question Export Tags (in combination with the data export tag) are used 123 | to label the response columns. 124 | 125 | #### Qualtrics Recode Values Editor 126 | ![](http://i.imgur.com/7fwPDli.png) 127 | 128 | #### Recode Values' Appearance in Response Data 129 | ![](http://i.imgur.com/HsrLRhe.png) 130 | -------------------------------------------------------------------------------- /vignettes/Sample-Surveys.Rmd: -------------------------------------------------------------------------------- 1 | --- 2 | title: "Sample Data included with QualtricsTools" 3 | vignette: > 4 | %\VignetteEngine{knitr::rmarkdown} 5 | %\VignetteIndexEntry{Sample Surveys} 6 | %\usepackage[utf8]{inputenc} 7 | --- 8 | 9 | There are several distinct surveys with sample response data included 10 | in the QualtricsTools package repository. The easiest way to access a 11 | set of sample data is to pass `sample_data=TRUE` to `get_setup`. 12 | ```{r sample_data} 13 | library(QualtricsTools) 14 | get_setup(sample_data=TRUE) 15 | ls(envir=globalenv()) 16 | ``` 17 | 18 | Under the covers, the `get_setup(sample_data=TRUE)` function 19 | call is directly loading the sample data saved in Rda files inside 20 | the `/data/` directory. Don't worry about understanding the construction of the 21 | `list.files.github` function that follows; it's just a tool I'm using 22 | to list files from the GitHub repository to show off the data that's 23 | included in the repository. 24 | ```{r} 25 | library(httr) 26 | 27 | list.files.github <- function(username = 'emmamorgan-tufts', repository = "QualtricsTools") { 28 | requireNamespace("httr") 29 | url <- paste0("https://api.github.com/repos/", username, "/", repository, "/git/trees/master?recursive=1", collapse="") 30 | req <- GET(url) 31 | stop_for_status(req) 32 | filelist <- unlist(lapply(content(req)$tree, "[", "path"), use.names = F) 33 | return(filelist) 34 | } 35 | 36 | qualtricstools_files <- list.files.github() 37 | grep("^data/[^/]*$", qualtricstools_files, value = TRUE, perl = TRUE) 38 | ``` 39 | 40 | However, there is more data contained in the `/data` directory than just the rda files listed above. "Sample Surveys" listed above is a directory which contains 41 | many more sample surveys and response datasets as QSF and CSV files. 42 | 43 | ```{r} 44 | # Let's get the directories inside the Sample Surveys folder: 45 | grep("^data/Sample Surveys/[^/]*$", qualtricstools_files, value = TRUE, perl = TRUE) 46 | ``` 47 | 48 | Each of these surveys and their corresponding response data can be downloaded from either the [GitHub repository](https://github.com/emmamorgan-tufts/QualtricsTools). Further, some surveys like the 49 | "Comment Coding" survey include extra data or extra formatting which are meant to test some of the 50 | more subtle features of QualtricsTools. If you clone the repository, then these files will also be 51 | available in the `/data` folder, but if `devtools::install_github('emmamorgan-tufts/QualtricsTools')` 52 | was used to install QualtricsTools, then these sample surveys will not be available in the 53 | locally installed version. 54 | 55 | ```{r} 56 | list.files( file.path(path.package("QualtricsTools"), "data/")) 57 | ``` 58 | -------------------------------------------------------------------------------- /vignettes/Source-Code-Layout.Rmd: -------------------------------------------------------------------------------- 1 | --- 2 | title: The Functions in Each Source Code File 3 | --- 4 | 5 | ```{r} 6 | tryCatch(library("httr"), error = function(e) { install.packages("httr")}, finally = library("httr")) 7 | tryCatch(library("rlist"), error = function(e) { install.packages("rlist")}, finally = library("rlist")) 8 | 9 | username <- 'emmamorgan-tufts' 10 | repository <- 'QualtricsTools' 11 | 12 | url <- paste0("https://api.github.com/repos/", username, "/", repository, "/git/trees/master?recursive=1", collapse="") 13 | 14 | req <- GET(url) 15 | 16 | R_source_files <- list.filter(content(req)$tree, grepl("R/", path)) 17 | 18 | list_of_functions_per_file <- list() 19 | 20 | for (file in R_source_files) { 21 | tf <- tempfile() 22 | filecontents <- getURL(file$url) 23 | # Oh. The file needs to be decoded from base64 and sha. 24 | # this won't work until that is done. 25 | write(x = filecontents, file = tf) 26 | temp.env <- new.env() 27 | sys.source(tf, envir = temp.env) 28 | functions <- lsf.str(envir=temp.env) 29 | list_of_functions_per_file <- c( 30 | list_of_functions_per_file, 31 | list('file' = file$path, 32 | 'functions' = functions) 33 | ) 34 | } 35 | --------------------------------------------------------------------------------