Description Usage Arguments Value
View source: R/func_process_choice_data.R
This function takes the data column from the output of
read_prpt
and runs four functions, binding the results in a
dataframe for easy manipulation:
get_phases
which separates the three phases of the task, saving them to the environment
phase
, which is initialized behind the scenes.
get_icons
which gets the icon information shown to the subject
per round.
get_choices
which gets the choice the subject
makes.
get_reinforcers
which gets the monetary
reinforcement the subject is shown after choosing an icon.
1 | process_choice_data(data, final_icon_rating = FALSE)
|
data |
The data output from |
final_icon_rating |
LOGICAL: FALSE by default for the majority of PRPT tasks that don't ask for final icon ratings. TRUE, and the phases will return those trials |
A dataframe 150 rows and 16 columns:
phase:
The phase these icons were displayed in (constant for each phase
object).
round: The round number these icons were displayed in, specific to the phase.
icon1: The icon presented in the first order position.
icon1Group: The group mapping for the icon presented in the first order position.
icon1Prob: The probability of getting a monetary reinforcement by choosing icon 1.
icon1Sign: The relative sign of the reinforcer (positive or negative) by choosing icon 1.
icon2: The icon presented in the second order position.
icon2Group: The group mapping for the icon presented in the second order position.
icon2Prob: The probability of getting a monetary reinforcement by choosing icon 2.
icon2Sign: The relative sign of the reinforcer (positive or negative) by choosing icon 2.
option: The option the subject chose.
chosen_icon: The icon the subject chose.
chosen_icon_group: The (payment weighting) group the chosen icon corresponds to.
chosen_icon_prob: The probability that the chosen icon leads to a monetary reinforcement.
reinforcer: The amount (dollars) the subject was reinforced with after making a choice.
cumulative_reward: The cumulative reward since the beginning of the game (phase 1, round 1).
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.