Download qualtrics data into R
This package contains convenience functions to work with
the Qualtrics API. It is under active development.
This project contains an R package to interact with the Qualtrics API. It is currently under development. I will add more functionality later.
Note that your institution must support API access and that it must be enabled for your account. Whoever manages your Qualtrics account can help you with this.
To install this package, execute the following in R:
This package depends on
stringr. Both dependencies will be installed when you install
Periodically check this repository for updates and execute
devtools::install_github("JasperHG90/qualtRics") to update.
Currently, the package contains three functions. It supports fetching a list of courses and their IDs from qualtrics, as well as downloading and reading a survey export.
Note that, while requests will work without a base url, it is desirable that you supply it to the functions when needed. Supplying the correct url will reduce the number of errors you'll experience. Please refer to the official documentation to find out your institution-specific base url.
Note that you can only export surveys that you own, or to which you have been given explicit administration rights.
Load the package:
Construct the header information:
head <- constructHeader(API.TOKEN = "<yourapitoken>")
Get a list of surveys:
surveys <- getSurveys(head, survey_baseurl="https://leidenuniv.eu.qualtrics.com/API/v3/responseexports/") # URL is for my own institution
Export a survey and load it into R:
mysurvey <- getSurvey(surveyID = surveys[]$id, headers = head, base_url = "https://leidenuniv.eu.qualtrics.com/API/v3/responseexports/", verbose = TRUE)
For specific information about the Qualtrics API, you can refer to the official documentation.
Should you encounter any bugs or issues, please report them here
If you have a request (like adding a new argument), please leave it here
- Added first three functions (
Functions in qualtRics
|constructHeader||Construct a header to send to qualtrics API|
|getSurvey||Export a survey and download into R|
|getSurveys||Retrieve a list of all active surveys that you own on qualtrics|
Last month downloads
Include our badge in your README