___________________________________________________________________________________________________________________ Pinatatask - Batch Script ___________________________________________________________________________________________________________________ Script Author: Katja Borchert, Ph.D. (katjab@millisecond.com) for Millisecond Software, LLC Date: 09-26-2022 last updated: 08-14-2023 by K. Borchert (katjab@millisecond.com) for Millisecond Software, LLC Script Copyright © 08-14-2023 Millisecond Software ___________________________________________________________________________________________________________________ BACKGROUND INFO ___________________________________________________________________________________________________________________ This script implements Millisecond Software's version of the 'Pinatatask' (Helfinstein et al, 2013), a child friendly monetary incentive delay task to induce anticipation of reward (and punishment) within a simple reaction time task. The Inquisit implementation is based on the publicly available eprime script published at: https://osf.io/43hfq/ !!Disclaimer: While we try to stay as faithful as possible to the original eprime script, the Inquisit implementation of the Pinata Task may still differ from it. This batch script runs a practice script followed by the test script and shares the practice performance category (based on hitrate) automatically with the test script. References for Pinata Task: Helfinstein SM, Kirwan ML, Benson BE, Hardin MG, Pine DS, Ernst M, Fox NA. Validation of a child-friendly version of the monetary incentive delay task. Soc Cogn Affect Neurosci. 2013 Aug;8(6):720-6. doi: 10.1093/scan/nss057. Epub 2012 May 7. PMID: 22569186; PMCID: PMC3739918. Dennison MJ, Rosen ML, Sambrook KA, Jenness JL, Sheridan MA, McLaughlin KA. Differential Associations of Distinct Forms of Childhood Adversity With Neurobehavioral Measures of Reward Processing: A Developmental Pathway to Depression. Child Dev. 2019 Jan;90(1):e96-e113. doi: 10.1111/cdev.13011. Epub 2017 Dec 21. PMID: 29266223; PMCID: PMC6013316. ___________________________________________________________________________________________________________________ Pinatatask - Practice Script ___________________________________________________________________________________________________________________ Script Author: Katja Borchert, Ph.D. (katjab@millisecond.com) for Millisecond Software, LLC Date: 09-26-2022 last updated: 05-02-2024 by K. Borchert (katjab@millisecond.com) for Millisecond Software, LLC Script Copyright © 05-02-2024 Millisecond Software ___________________________________________________________________________________________________________________ BACKGROUND INFO ___________________________________________________________________________________________________________________ This script implements Millisecond Software's version of the 'Pinatatask' (Helfinstein et al, 2013), a child friendly monetary incentive delay task to induce anticipation of reward (and punishment) within a simple reaction time task. The Inquisit implementation is based on the publicly available eprime script published at: https://osf.io/43hfq/ !!Disclaimer: While we try to stay as faithful as possible to the original eprime script, the Inquisit implementation of the Pinata Task may still differ from it. References: Helfinstein SM, Kirwan ML, Benson BE, Hardin MG, Pine DS, Ernst M, Fox NA. Validation of a child-friendly version of the monetary incentive delay task. Soc Cogn Affect Neurosci. 2013 Aug;8(6):720-6. doi: 10.1093/scan/nss057. Epub 2012 May 7. PMID: 22569186; PMCID: PMC3739918. Dennison MJ, Rosen ML, Sambrook KA, Jenness JL, Sheridan MA, McLaughlin KA. Differential Associations of Distinct Forms of Childhood Adversity With Neurobehavioral Measures of Reward Processing: A Developmental Pathway to Depression. Child Dev. 2019 Jan;90(1):e96-e113. doi: 10.1111/cdev.13011. Epub 2017 Dec 21. PMID: 29266223; PMCID: PMC6013316. ___________________________________________________________________________________________________________________ TASK DESCRIPTION ___________________________________________________________________________________________________________________ Participants are asked to whack a Pinata as fast as they can to 'open' it and win its content (here: a varying number of stars: 0,1,2, or 4). Before they can hit the Pinata, only half the Pinata is revealed to the participant to show how many stars they can win ('cue'). Once the entire Pinata is revealed, participants have to be very fast to press the spacebar to whack the pinata. If they succeed, they win the stars. If they don't succeed, no starts are won. ___________________________________________________________________________________________________________________ DURATION ___________________________________________________________________________________________________________________ the default set-up of the script takes appr. 5 minutes to complete ___________________________________________________________________________________________________________________ DATA OUTPUT DICTIONARY ___________________________________________________________________________________________________________________ The fields in the data files are: (1) Raw data file: 'pinatatask_practice_raw*.iqdat' (a separate file for each participant) build: The specific Inquisit version used (the 'build') that was run computer.platform: the platform the script was run on (win/mac/ios/android) date, time: date and time script was run subject: with the current subject id group: with the current group id session: with the current session id //Parameter settings: numberOfBlocks: the number of blocks to run trialsPerBlock: the number of trials per block totalTrials: the total number of trials to run based on parameters.trialsPerBlock x parameters.numberOfBlocks numberStimuli: the number of different animal stimuli used for this experimental setup (10, 11, or 12) depends on number of trialsPerBlock (see section Editable Parameters for more info) numberTrialTypes: the number of different trialtypes to run (= 4 levels * number of stimuli) either 40, 44, or 48 balancedDesignTrialTypes: 1 = the chosen number of trialsPerBlock and numberOfBlocks results in a balanced design that runs each of the (40/44/48)trialtypes equally often 0 = the chosen number of trialsPerBlock and numberOfBlocks does not result in a balanced design in regard to trialtypes. The (40/44/48) trialtypes are not run equally often. targetDuration: the duration (in ms) of the target used for practice trials practicePerformanceCategory: the practice performance category (based on practice hit rate) used to calibrate target duration during the test Note: participants are grouped into practice performance groups 1-5 at the end of practice group5: practice hit rate > 79% group4: 54% < practice hit rate <= 79% group3: 29% < practice hit rate <= 54% group2: 4%< practice hit rate <= 29% group1: practice hit rate <= 4% (hit rates from eprime script) blockCode, blockNum: the name and number of the current block (built-in Inquisit variable) trialCode, trialNum: the name and number of the currently recorded trial (built-in Inquisit variable) Note: trialNum is a built-in Inquisit variable; it counts all trials run; even those that do not store data to the data file. Note: the final/complete trial outcome variables are stored in trial.feedbackDelay //custom counters blockCounter: tracks the number of blocks run trialCounterPerBlock: tracks the trial count per block trialCounterTotal: tracks the trial count across entire task cueAnimal: the itemnumber of the current cue animal level: the level (number of stars that can be won) of the current trial (0,1,2,4) anticipatoryDelay: the duration (in ms) of the current anticipatory delay itiDuration: the duration (in ms) of the current iti image: the current target image presented //custom DVs responseCategory: Note: the accurate responseCategory will only be known in trial.feedbackDelay if the responseCategory is empty during trial.pinata, a response can still be made during the feedbackdelay trial which is counted as a 'miss' - if no response is given at all, it's a 'no response' hit: spacebar was pressed during target duration miss: spacebar was pressed after target duration too early: spacebar was pressed during cue presentation OR anticipatory delay (before target was presented) no response: spacebar was not pressed at all acc: 1 = spacebar was pressed during target duration; 0 = otherwise targetDuration: the duration (in ms) of the target rt: the response time (in ms) relative to target onset negative values: spacebar was pressed before target appeared feedbackDelay: the duration (in ms) assigned to the feedback delay period based on previous responses total: the total number of stars collected across experiment starCounter: the total number of stars that could be collected across experiment //built-in DVs: response: the response of participant (scancode of response button) latency: response latency (in ms); measured from: onset of trial picture.target.stimulusOnset: the stimulusonset time (in ms) of the last target in trial.pinata (2) Summary data file: 'pinatatask_practice_summary*.iqdat' (a separate file for each participant) inquisit.version: Inquisit version run computer.platform: the platform the script was run on (win/mac/ios/android) startDate: date script was run startTime: time script was started subjectId: assigned subject id number groupId: assigned group id number sessionId: assigned session id number elapsedTime: time it took to run script (in ms); measured from onset to offset of script completed: 0 = script was not completed (prematurely aborted); 1 = script was completed (all conditions run) //Parameter settings: numberOfBlocks: the number of blocks to run trialsPerBlock: the number of trials per block totalTrials: the total number of trials to run based on parameters.trialsPerBlock x parameters.numberOfBlocks numberStimuli: the number of different animal stimuli used for this experimental setup (10, 11, or 12) depends on number of trialsPerBlock (see section Editable Parameters for more info) numberTrialTypes: the number of different trialtypes to run (= 4 levels * number of stimuli) either 40, 44, or 48 balancedDesignTrialTypes: 1 = the chosen number of trialsPerBlock and numberOfBlocks results in a balanced design that runs each of the (40/44/48)trialtypes equally often 0 = the chosen number of trialsPerBlock and numberOfBlocks does not result in a balanced design in regard to trialtypes. The (40/44/48) trialtypes are not run equally often. targetDuration: the duration (in ms) of the target used for practice trials practicePerformanceCategory: the practice performance category (based on practice hit rate) used to calibrate target duration during the test Note: participants are grouped into practice performance groups 1-5 at the end of practice group5: practice hit rate > 79% group4: 54% < practice hit rate <= 79% group3: 29% < practice hit rate <= 54% group2: 4%< practice hit rate <= 29% group1: practice hit rate <= 4% (hit rates from eprime script) ___________________________________________________________________________________________________________________ EXPERIMENTAL SET-UP ___________________________________________________________________________________________________________________ /////PRACTICE//// Default setup (check section Editable Parameters for changes you can make to the default setup) ● 4 blocks of 10 trials (40 trials total) (number of blocks as well as number of trials can be edited) ● Across 4 blocks: (40 trials)* - 10 animals presented with 4 levels of reward (0, 1, 2, 4) - the resulting 40 trials are presented in a random order ● Trial Sequence: 1. Cue - part of animal that shows the number of stars that can be won (cue duration: fixed at 1500ms - editable parameter) 2. Anticipatory Delay - cue removed, shows a basket (see info below for duration of anticipatory delay) 3. (active )Target - the entire animal is presented in the center (practice target duration: fixed at 275ms - editable parameter) 4. inactive Target during Feedback Delay - (see info below for delay duration) 5. Feedback (feedback duration: fixed at 1500 - editable parameter) 6. Intertrialinterval (iti) - shows a fixation cross (see info below for iti duration) ● each block starts with a 'getReady' trial and ends with a rest trial (except for last block) ● repeat of practice session optional (editable parameters) //////Duration Explanations////// ● Anticipatory Delay Duration: The script run 3 anticipatory delays (1000, 1500, 2000 - editable parameters). The delays are randomly assigned to each trial If the total number of trials is divisible by 3, all three delays should be run equally often ● Target Duration: 'active' target active Target Duration set at 275ms (editable parameter) Note: the target image is presented for a total of 990ms (parameters.combinedTargetDelayDurationMS) total for each participant but it's an active target only for 275ms of that period ● Feedback Delay Duration: 'inactive' target The feedback delay duration is calculated based on: too early: 1500ms (parameters.combinedTargetDelayDurationMS) hits: 1500ms (parameters.combinedTargetDelayDurationMS) - values.RT (hitRT) miss: 1500ms (parameters.combinedTargetDelayDurationMS) - values.targetDuration Note: The target picture is presented the same duration for each participant (here: 1500ms) but it's only the 'active' target for values.targetDuration (hits can only occur when the target is still 'active') ● ITI Duration: The iti durations are calculated the same way the anticipatory delays are calculated ___________________________________________________________________________________________________________________ STIMULI ___________________________________________________________________________________________________________________ E-prime task as well as stimuli downloaded from: https://osf.io/43hfq/ ___________________________________________________________________________________________________________________ INSTRUCTIONS ___________________________________________________________________________________________________________________ Instructions are based on the instructions provided by the original eprime script ___________________________________________________________________________________________________________________ EDITABLE CODE ___________________________________________________________________________________________________________________ check below for (relatively) easily editable parameters, stimuli, instructions etc. Keep in mind that you can use this script as a template and therefore always "mess" with the entire code to further customize your experiment. The parameters you can change are: ___________________________________________________________________________________________________________________ Pinatatask - Test Script ___________________________________________________________________________________________________________________ Script Author: Katja Borchert, Ph.D. (katjab@millisecond.com) for Millisecond Software, LLC Date: 09-26-2022 last updated: 08-14-2023 by K. Borchert (katjab@millisecond.com) for Millisecond Software, LLC Script Copyright © 08-14-2023 Millisecond Software ___________________________________________________________________________________________________________________ BACKGROUND INFO ___________________________________________________________________________________________________________________ This script implements Millisecond Software's version of the 'Pinatatask' (Helfinstein et al, 2013), a child friendly monetary incentive delay task to induce anticipation of reward (and punishment) within a simple reaction time task. The Inquisit implementation is based on the publicly available eprime script published at: https://osf.io/43hfq/ !!Disclaimer: While we try to stay as faithful as possible to the original eprime script, the Inquisit implementation of the Pinata Task may still differ from it. References: Helfinstein SM, Kirwan ML, Benson BE, Hardin MG, Pine DS, Ernst M, Fox NA. Validation of a child-friendly version of the monetary incentive delay task. Soc Cogn Affect Neurosci. 2013 Aug;8(6):720-6. doi: 10.1093/scan/nss057. Epub 2012 May 7. PMID: 22569186; PMCID: PMC3739918. Dennison MJ, Rosen ML, Sambrook KA, Jenness JL, Sheridan MA, McLaughlin KA. Differential Associations of Distinct Forms of Childhood Adversity With Neurobehavioral Measures of Reward Processing: A Developmental Pathway to Depression. Child Dev. 2019 Jan;90(1):e96-e113. doi: 10.1111/cdev.13011. Epub 2017 Dec 21. PMID: 29266223; PMCID: PMC6013316. ___________________________________________________________________________________________________________________ TASK DESCRIPTION ___________________________________________________________________________________________________________________ Participants are asked to whack a Pinata as fast as they can to 'open' it and win its content (here: a varying number of stars: 0,1,2, or 4). Before they can hit the Pinata, only half the Pinata is revealed to the participant to show how many stars they can win ('cue'). Once the entire Pinata is revealed, participants have to be very fast to press the spacebar to whack the pinata. If they succeed, they win the stars. If they don't succeed, no starts are won. ___________________________________________________________________________________________________________________ DURATION ___________________________________________________________________________________________________________________ the default set-up of the script takes appr. 15 minutes to complete ___________________________________________________________________________________________________________________ DATA OUTPUT DICTIONARY ___________________________________________________________________________________________________________________ The fields in the data files are: (1) Raw data file: 'pinatatask_test_raw*.iqdat' (a separate file for each participant) build: The specific Inquisit version used (the 'build') that was run computer.platform: the platform the script was run on (win/mac/ios/android) date, time: date and time script was run subject: with the current subject id group: with the current group id session: with the current session id //Parameter settings: numberOfBlocks: the number of blocks to run trialsPerBlock: the number of trials per block totalTrials: the total number of trials to run based on parameters.trialsPerBlock x parameters.numberOfBlocks numberStimuli: the number of different animal stimuli used for this experimental setup (10, 11, or 12) depends on number of trialsPerBlock (see section Editable Parameters for more info) numberTrialTypes: the number of different trialtypes to run (= 4 levels * number of stimuli) either 40, 44, or 48 balancedDesignTrialTypes: 1 = the chosen number of trialsPerBlock and numberOfBlocks results in a balanced design that runs each of the (40/44/48) trialtypes equally often 0 = the chosen number of trialsPerBlock and numberOfBlocks does not result in a balanced design in regard to trialtypes. The (40/44/48) trialtypes are not run equally often. calibrateTargetDurations: 1 = use practice performance to calibrate target duration 0 = do not use practice performance to calibrate target duration practicePerformanceCategory: the practice performance category used to calibrate target duration //Note: participants are grouped into practice performance groups 1-5 //group5: practice hit rate > 79% //group4: 54% < practice hit rate <= 79% //group3: 29% < practice hit rate <= 54% //group2: 4%< practice hit rate <= 29% //group1: practice hit rate <= 4% //(hit rates from eprime script) targetDuration: the duration (in ms) of the target used for the test trials blockCode, blockNum: the name and number of the current block (built-in Inquisit variable) trialCode, trialNum: the name and number of the currently recorded trial (built-in Inquisit variable) Note: trialNum is a built-in Inquisit variable; it counts all trials run; even those that do not store data to the data file. Note: the final/complete trial outcome variables are stored in trial.feedbackDelay //custom counters: blockCounter: tracks the number of blocks run trialCounterPerBlock: tracks the trial count per block trialCounterTotal: tracks the trial count across entire task cueAnimal: the itemnumber of the current cue animal level: the level (number of stars that can be won) of the current trial (0,1,2,4) anticipatoryDelay: the duration (in ms) of the current anticipatory delay itiDuration: the duration (in ms) of the current iti image: the current target image presented //custom DVs responseCategory: Note: the accurate responseCategory will only be known in trial.feedbackDelay if the responseCategory is empty during trial.pinata, a response can still be made during the feedbackdelay trial which is counted as a 'miss' - if no response is given at all, it's a 'no response' hit: spacebar was pressed during target duration miss: spacebar was pressed after target duration too early: spacebar was pressed during cue presentation OR anticipatory delay (before target was presented) no response: spacebar was not pressed at all acc: 1 = spacebar was pressed during target duration; 0 = otherwise targetDuration: the duration (in ms) of the target rt: the response time (in ms) relative to target onset negative values: spacebar was pressed before target appeared feedbackDelay: the duration (in ms) assigned to the feedback delay period based on previous responses totalStars: the total number of stars collected across experiment starCounter: the total number of stars that could be collected across experiment //built-in DVs: response: the response of participant (scancode of response button) latency: response latency (in ms); measured from: onset of trial picture.target.stimulusOnset: the stimulusonset time (in ms) of the last target in trial.pinata (2) Summary data file: 'pinatatask_test_summary*.iqdat' (a separate file for each participant) inquisit.version: Inquisit version run computer.platform: the platform the script was run on (win/mac/ios/android) startDate: date script was run startTime: time script was started subjectId: assigned subject id number groupId: assigned group id number sessionId: assigned session id number elapsedTime: time it took to run script (in ms); measured from onset to offset of script completed: 0 = script was not completed (prematurely aborted); 1 = script was completed (all conditions run) //Parameter settings: numberOfBlocks: the number of blocks to run trialsPerBlock: the number of trials per block totalTrials: the total number of trials to run based on parameters.trialsPerBlock x parameters.numberOfBlocks numberStimuli: the number of different animal stimuli used for this experimental setup (10, 11, or 12) depends on number of trialsPerBlock (see section Editable Parameters for more info) numberTrialTypes: the number of different trialtypes to run (= 4 levels * number of stimuli) either 40, 44, or 48 balancedDesignTrialTypes: 1 = the chosen number of trialsPerBlock and numberOfBlocks results in a balanced design that runs each of the (40/44/48) trialtypes equally often 0 = the chosen number of trialsPerBlock and numberOfBlocks does not result in a balanced design in regard to trialtypes. The (40/44/48) trialtypes are not run equally often. calibrateTargetDurations: 1 = use practice performance to calibrate target duration 0 = do not use practice performance to calibrate target duration practicePerformanceCategory: the practice performance category used to calibrate target duration targetDuration: the duration (in ms) of the target used for the test trials //summary data:// //totals: totalStars: the total number of stars collected collected across experiment starCounter: the total number of stars that could be collected across experiment //overall: hitCounter: the number of hits propHits: proportion of hits relative to all trials meanHitRT: mean hit response time (in ms) missCounter: the number of misses anticipationCounter: the number of 'too early' responses noResponseCounter: the number of 'no responses' //by level (incentive condition): hitCounterLevel0: the number of hits for level0 trials propHitsLevel0: proportion of hits relative to all trials for level0 trials meanHitRTLevel0: mean hit response time (in ms) for level0 trials missCounterLevel0: the number of misses for level0 trials anticipationCounterLevel0: the number of 'too early' responses for level0 trials noResponseCounterLevel0: the number of 'no responses' for level0 trials (same for level1,2,4) ___________________________________________________________________________________________________________________ EXPERIMENTAL SET-UP ___________________________________________________________________________________________________________________ /////PRACTICE///// Practice can be run by script pinatatask_practice.iqjs. The practice script is run with a fixed target duration. The target duration used for the test can be calibrated using participants' practice performance (see section Editable Parameters). In short: the practice script categorizes participants' hit performance into 5 different categories which can be used by the test script to adapt the target duration (see section Editable Parameters for more info). The practice script can be run independently of the test script or via batch script pinatatask_batch.iqjs. If run via the batch script, the practice performance category (1-5) is automatically shared with the test script. /////TEST//// Default setup (check section Editable Parameters for changes you can make to the default setup) ● 6 blocks of 22 trials (132 trials total) (number of blocks as well as number of trials can be edited) ● Across 2 blocks: (44 trials)* - 11 animals presented with 4 levels of reward (0, 1, 2, 4) - the resulting 44 trials are presented in random order ● Trial Sequence: 1. Cue - part of animal that shows the number of stars that can be won (cue duration: fixed at 1000ms - editable parameter) 2. Anticipatory Delay - cue removed, shows a basket (see info below for variable duration of anticipatory delay) 3. active Target - the entire animal is presented in the center (see info below for target duration) 4. inactive Target during Feedback Delay - (see info below for delay duration) 5. Feedback (feedback duration: fixed at 1490 - editable parameter) 6. Intertrialinterval (iti) - shows a fixation cross (see info below for variable iti duration) ● each block starts with a 'getReady' trial and ends with a rest trial (except for last block) //////Duration Explanations////// ● Anticipatory Delay Duration: The script run 3 anticipatory delays (1000, 1500, 2000 - editable parameters). The delays are randomly assigned to each trial with the following constraints: - each anticipatory delay is run equally often across the task (as much as possible given the number of trials to run per block and blocks to run) Default setup: 6 blocks run 22 trials => 3 blocks run 22 repetitions of each of the 3 itis. After 6 blocks, each iti is run 44 times. ● Target Duration: presents the 'active' target If the active target duration should be calibrated based on practice performance: At the end of practice, participants are grouped into 5 practice performance categories based on their hit performance: group5: practice hit rate > 79% group4: 54% < practice hit rate <= 79% group3: 29% < practice hit rate <= 54% group2: 4%< practice hit rate <= 29% group1: practice hit rate <= 4% (hit rates from eprime script) The performance category (1-5) can be entered at the start of the test script (optional). In that case, different target durations are used for each of the 5 categories: group5: 225ms group4: 275ms group3: 325ms group2: 375ms group1: 425ms (see section Editable Parameters for adjustments) ● Feedback Delay Duration: presents the inactive target The feedback delay duration is calculated based on: too early: 1500ms (parameters.combinedTargetDelayDurationMS) hits: 1500ms (parameters.combinedTargetDelayDurationMS) - values.RT (hitRT) miss: 1500ms (parameters.combinedTargetDelayDurationMS) - values.targetDuration Note: The target picture is presented the same duration for each participant (here: 1500ms) but it's only the 'active' target for values.targetDuration (hits can only occur when the target is still 'active') ● ITI Duration: The iti durations are calculated the same way the anticipatory delays are calculated ___________________________________________________________________________________________________________________ STIMULI ___________________________________________________________________________________________________________________ E-prime task as well as stimuli downloaded from: https://osf.io/43hfq/ ___________________________________________________________________________________________________________________ INSTRUCTIONS ___________________________________________________________________________________________________________________ Instructions are based on the instructions provided by the original eprime script ___________________________________________________________________________________________________________________ EDITABLE CODE ___________________________________________________________________________________________________________________ check below for (relatively) easily editable parameters, stimuli, instructions etc. Keep in mind that you can use this script as a template and therefore always "mess" with the entire code to further customize your experiment. The parameters you can change are: