User Manual: Inquisit Mirror Tracing Persistence Task


___________________________________________________________________________________________________________________	

								Computerized Mirror-Tracing Persistence Task (MTPT-C)
								(German instructions)
___________________________________________________________________________________________________________________	


Script Author: Katja Borchert, Ph.D. (katjab@millisecond.com) for Millisecond Software, LLC
Date: 11-19-2024
last updated:  01-02-2025 by K. Borchert (katjab@millisecond.com) for Millisecond Software, LLC

Script Copyright © 01-02-2025 Millisecond Software

German translation provided by K. Borchert for Millisecond Software

___________________________________________________________________________________________________________________
BACKGROUND INFO 	
___________________________________________________________________________________________________________________
This script implements Millisecond Software's version of the Computerized Mirror-Tracing Persistence Task 
(MTPT-C) inspired by Strong et al (2003) and described in Brown et al (2019).
The MTPT-C is a test to measure distress tolerance.

Researchers can select to run the task with an absolute screen size to ensure that distances
stay the same across devices. The default setting is to use proportional sizing.
Go to section Defaults for more information.

Researcher can also set whether the 'mirroring' only applies to the y-axis (more like a mirror) or whether the
x-coordinates should also be reverted. The default setting only inverts the y-coordinates in this script.
See section Parameters for more information.


Reference:											

Brown, R. C., Overstreet, C., Sheerin, C., Berenz, E., Hawn, S., Pickett, T., McDonald, S., 
Danielson, C. K., & Amstadter, A. B. (2019). The Nomological Network of a Behavioral 
Distress Tolerance Task in Veterans. Journal of Traumatic Stress, 31(6), 876–885. 
https://doi.org/10.1002/jts.22349

Strong, D. R., Lejuez, C. W., Daughters, S. B., Marinello, M., Kahler, C. W., & Brown, R. A. (2003). 
The computerized mirror tracing task, version 1. 
In Unpublished manual.

___________________________________________________________________________________________________________________
TASK DESCRIPTION	
___________________________________________________________________________________________________________________

Participants are asked to trace three shapes in increasing levels of difficulty (e.g. straight line,
square, 5-pointed star) while using the shapes' mirror images as guides. 
Each level is run under time-constraints. Any time a mistake (e.g. tracing outside the shape) is made
or participants hesitate too long (2s), the task is started over.
Level3 tasks offers a quit button. The time until participants decide to quit task 3 is taken 
as the main DV.
___________________________________________________________________________________________________________________	
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: 'mirrortracingpersistencetask_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

//Design Parameters
tracingHand:				dominant vs. non-dominant 
runAdaptiveLevels:			true (1) vs. false (0)
invertXAxis:				true (1) vs. false (0) (Note: the y-axis coordinates are always inverted/mirrored)

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. 
								
level:						1,2, or 3
tracingShape:				line, rightAngle, square, circle, star
countTrials:				number of trials started for the current shape
success: 					1 = shape successfully completed; 0 = otherwise
taskDurationMS:				the duration (in ms) spent on the task
level3Quit:					1 = participant pressed quit-button to terminate level3; 0 = otherwise
								
//built-in variables								
response:					the response of participant (scancode of response button)
correct:					correctness of response (1 = correct, 0 = error)
latency:					response latency (in ms); measured from:


(2) Summary data file: 'mirrortracingpersistencetask_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)

//Design Parameters
tracingHand:				dominant vs. non-dominant 
runAdaptiveLevels:			true (1) vs. false (0)
invertXAxis:				true (1) vs. false (0) (Note: the y-axis coordinates are always inverted/mirrored)

level1Task: 				name of shape run as level1
level1DurationMS: 			duration spent on level1
level1TrialCount: 			number of trials started on level1
level1Success:				1 = level1 was successfully completed; 0 = otherwise

level2Task: 				name of shape run as level2
level2DurationMS: 			duration spent on level2
level2TrialCount: 			number of trials started on level2
level2Success:				1 = level2 was successfully completed; 0 = otherwise

level3Task: 				name of shape run as level3
level3DurationMS: 			duration spent on level3 (whether or not quit button was pressed)
level3TrialCount: 			number of trials started on level3
level3Success:				1 = level3 was successfully completed; 0 = otherwise
level3Quit:					1 = participant pressed quit-button to terminate level3; 0 = otherwise

level3QuitRT:				the duration (in ms) spent on level3 until the quit button was pressed
							(if quit button was NOT pressed, this variable will be empty)
							
___________________________________________________________________________________________________________________	
EXPERIMENTAL SET-UP 
___________________________________________________________________________________________________________________	

This script runs 3 mirror tracing tasks with shapes that increase in difficulty from level1 to level3.
The shapes can be selected under section Editable Lists.
By, default this scripts runs the following fixed levels:

LEVEL1:
● Level1 a Vertical Line Tracing Task
● timeout for Level1 is 1min (default; can be edited under section Editable Parameters)

LEVEL2:
● Level2 is a Square Tracing Task 
● timeout for Level2 is 3min (default; can be edited under section Editable Parameters)

LEVEL3:
● Level3 is a 5-pointed Star Tracing Task 
● timeout for Level3 is 10min (default; can be edited under section Editable Parameters)
● Level3 provides a 'QUIT' button that can be pressed any time a participants wants to terminate
the task prematurely

///Applies to ALL levels:
Any time participants 
- venture off the shape's path OR
- take too long (more than 2s) to make another move along the shape's path
a buzzer sounds and participants have to restart tracing.

!!!!Note: you can easily set this script to use 'AdaptiveLevelTesting' (see section Editable Parameters)


/////////////////////////////////////////
//////Adaptive Level Testing Info////////
/////////////////////////////////////////

This script provides code for the following tracing tasks:
- vertical line tracing (lowest difficulty level)
- right angle tracing
- square tracing
- circle tracing
- 5-pointed star tracing

- check section Editable Parameters (-> parameters.runAdaptiveLevels) if you want to use
adaptive level testing

IF parameters.runAdaptiveLevels is set to 'TRUE', the script adapts the levels 
based on performance as follows:

Level1: always the Vertical Line Tracing Task
● if completed in under half the time allotted OR less than 5 resets-> level2 = square tracing
● else -> level2 = right angle tracing

Level2: 
if level2 = square
● if completed in under half the time allotted  OR less than 5 resets -> level3 = star tracing
● else -> level3 = circle tracing

if level2 = right angle
● if completed in under half the time allotted OR less than 5 resets -> level3 = circle tracing
● else -> level3 = square tracing

NOTE: level adjustments are not described in detail in Brown et al (2019).
The implemented adjustments were decided upon by Millisecond.

___________________________________________________________________________________________________________________	
STIMULI
___________________________________________________________________________________________________________________

provided by Millisecond Software - can be edited under section 'Editable Stimuli'

Buzzer: recorded from freesound.org
Soundfile licensed under the Creative Commons 0 License.
___________________________________________________________________________________________________________________	
INSTRUCTIONS 
___________________________________________________________________________________________________________________

provided by Millisecond Software - can be edited under section 'Editable Instructions'
___________________________________________________________________________________________________________________	
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:

//color parameter
/ canvasColor = white			//Display color of the actively used portion of the screen (the 'canvas')	
									//Note: if set to a color other than the screencolor, the active canvas
									//appears 'anchored' on the screen regardless of monitor size
/ screenColor = black 			//Color of the screen not used by the canvas ('inactive screen')
/ defaultTextColor = black		//Default color of text items presented on active canvas

//CANVAS SIZING PARAMETERS
//sizing Parameters in RELATIVE measurements relative to CANVAS HEIGHT
//NOTE: to run the script with ABSOLUTE screen measurements, go to 'defaults' and set 
//canvasSize to absolute measurements

/ tracingLineHeightPct = 30%			//the height of the TracingLine in canvas height percentage 

/ tracingSquareHeightPct = 35%			//the height of the TracingSquare in canvas height percentage
										
/ tracingCircleDiameterPct = 35%		//the diameter of the circle in canvas height percentage	
								
/ tracingStarheightPct = 45%			//the height of the TracingStar in canvas height percentage							
						
																														
/ trackWidthPct = 2%					//the width of the tracing track in canvas height percentage
										//Note: the width is slightly changed for the star task; this is done automatically by the script

/ pencilWidthPct = 1%					//the width of the tracing line (drawn by participant) in canvas height percentage

/ targetZoneDiameterPct = 5%			//the diameter of the target (also start) zone in canvas height percentage
									
								
////////////////////////////							
///////Instructions:////////
////////////////////////////						
										
/ tracingHand = "dominant"				//choose from: "dominant", "non-dominant", "left", "right"	


			
////////////////////////////							
///////Design://////////////
////////////////////////////

//NOTE: level1 is always the LINE Tracing Task regardless of setting of parameters.runAdaptiveLevels
/ runAdaptiveLevels = false		//true: level1 = line tracing; level2/level3 adaptive
								//the right angle OR a square depending on how difficult the line task was
								//for participant (difficulty of a task estimated via completion time and performance)
																						
								//false: no adaptive levels are run (choose fixed sequence of tests below under Editable LIsts)														
																				
/ showTaskTimer = true			//true = a watch is presented on screen that displays how much is left for the current task	
								//false = no watch is presented on screen
								
/ invertXAxis = false			//true = the mirror inverts the vertical AND horizontal cursor positions (even more challenging)
								//false = the mirror inverts ONLY the vertical cursor positions ('true' mirroring)
								
//Timing Parameters:
/ trialTimeoutMS = 2000			//movement timeout in ms: if no tracing movement is detected after this time, 
								//the trial times out and participant has to restart
											
/ level1TimeoutMS = 60000		//the timeout (in ms) for level1 task
/ level2TimeoutMS = 180000		//the timeout (in ms) for level2 task
/ level3TimeoutMS = 600000      //the timeout (in ms) for level3 task		


For non-adaptive testing you can further set the sequence of shapes under section
Editable Lists.