-
Notifications
You must be signed in to change notification settings - Fork 17
Installation
To use MTurkR, you need to have R installed on your machine. It is available for multiple platforms from CRAN.
Once R is installed and open, the latest stable release of MTurkR can be installed from your local CRAN mirror and loaded using:
install.packages("MTurkR")
library("MTurkR")To install the Graphical User Interface:
install.packages("MTurkRGUI")
library("MTurkRGUI")The latest stable development releases of MTurkR and the GUI can be installed from the cloudyr drat repository:
install.packages(c("MTurkR", "MTurkRGUI"),
repos = c(getOption("repos"), "http://cloudyr.github.io/drat"))Potentially unstable releases can be installed directly from GitHub using devtools:
# latest (not necessarily stable) version from GitHub
if (!require("devtools")) {
install.packages("devtools")
library("devtools")
}
# Core package
install_github("leeper/MTurkR")
# GUI
install_github("leeper/MTurkRGUI")Once installed, you will need to supply your AWS Access Key ID and Secret Key (your "keypair") to use the package. You can do this using system environment variables (e.g., by setting them up system-wide, by incorporating them into the R startup procedures, in a .Renviron file in your working directory, or using the Sys.setenv() function). The values should be set as variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY, respectively. When MTurkR is loaded, these environment variables will automatically be retrieved.
Your keypair can be generated on the IAM Management Console under the heading Access Keys. Note that you only have access to your secret key once. After it is generated, you need to save it in a secure location. New keypairs can be generated at any time if yours has been lost, stolen, or forgotten.
Specifying your keypair via environment variables simplifies use of MTurkR and protects those credentials from being logged by R's console history, but you can always manually specify your keypair in each function call as a two-element character vector for the keypair argument.
.