Introduction
People typically respond faster to target stimuli whose location has previously been "cued". However, this effect turns around when the interval between cue and target is over 300 m (Klein, 20000). This latter effect is known as Inhibition Of Return (IOR).
Interestingly, IOR is not observed when the cue is endogenous and when no saccades are being made.
In a study by Filotheo and colleagues (1997), healthy individuals and people suffering from Parkinson’s disease were compared in both endogenous and exogenous cueing. The prediction is that when people are not making saccades (e.g., because they have been instructed to keep fixating on the fixation point), there should only be IOR in the exogenous condition. But is that true? Try it yourself!
About this implementation
This implementation requires a numeric keyboard!
Run the demo
In this example, you will |
Data output file
In PsyToolkit, the data output file is simply a textfile. The save line of the PsyToolkit experiment script determines what is being saved in the data output file. Typically, for each experimental trial, you would have exactly one line in your text file, and each number/word on that line gives you the information you need for your data analysis, such as the condition, response speed, and whether an error was made. |
Meaning of the columns in the output datafile. You need this information for your data analysis.
Colum |
Meaning BLOCKNAME &training $cuetype $valid $SOA $waitkeytime $tooearly $cue $target STATUS RT |
1 |
Name of block |
2 |
Training (0=no training block, 1=training block) |
3 |
Type of cue (1=endogenous, 2=exogenous) |
4 |
cue validity (0=invalid, 1=valid) |
5 |
soa (time between cue and target, 50, 150, 250, 1000 ms) |
6 |
the time the participant waited to press the central button |
7 |
was response too early (0=no, 1=yes) |
8 |
cue position (1=left, 2=top, 3=right, 4=bottom) |
9 |
target position (1=left, 2=top, 3=right, 4=bottom) |
10 |
Status (1=correct, 2=wrong, 3=timeout) |
11 |
Reaction time (ms) |
PsyToolkit code
Click to expand the PsyToolkit script code (part of zip file below)
# Based on a study by Filotheo et al: Journal of the International
# Neuropsychological Society (1997), 3, 337–347. Adapted for teaching
# using PsyToolkit, http://www.psytoolkit.org by G. Stoet, 2015.
options
fullscreen
bitmapdir stimuli
escape
fonts
arial 12
bitmaps
box_grey
box_yellow
cue_down
cue_left
cue_right
cue_up
press5
fixpoint1
fixpoint2
fixpoint3
fixpoint4
fixpoint_green
targetstim
real
happy
sad
slow
tooearlywarning
instructions1
instructions2
instructions3
instructions4
training_endo
training_exo
real_endo
real_exo
numlocktest
numlockquestion
numlockconfirmation
table numlocktable
cue_up 0 -200 3
cue_down 0 200 5
cue_left -200 0 2
cue_right 200 0 4
task numlocktester
table numlocktable
keys kp5 kp4 kp8 kp6 kp2
show bitmap press5
readkey 1 20000
clear -1
show bitmap @1 @2 @3
readkey @4 20000
clear -1
if STATUS == CORRECT
show bitmap happy
delay 500
clear -1
fi
if STATUS != CORRECT
show bitmap numlockquestion
delay 5000
clear -1
fi
######################################################################
## notes:
## the implementation does not use a table, but instead does
## everything using the random function.
## in the endogenous condition (arrow points at cue or not,
## 80% validity)
######################################################################
## in the exogenous task, the cue is the box itself (bright)
## the validity is only 50%
task exogenous ## cue => box yellow border
keys kp5 kp4 kp8 kp6 kp2
set $cuetype 2 # 1 = endo ; 2 = exo
set $tooearly 0
set $SOA random from 50 150 250 1000
## choose valid/invalid
set $valid random from 1 0 ## this means 50%, valid=1,invalid=0
if $valid == 1 # if valid, cue and target are the same
set $cue random 1 4
set $target $cue
fi
if $valid == 0 # if not valid, cue and target must be different
set $cue random 1 4
set $target random 1 4
while $cue == $target
set $target random 1 4
while-end
fi
#############################################
show bitmap box_grey -200 0
show bitmap box_grey 0 -200
show bitmap box_grey 200 0
show bitmap box_grey 0 200
delay 100
show bitmap press5
readkey 1 50000
set $waitkeytime RT
clear -1
##############################################
show bitmap fixpoint1
delay 150
show bitmap fixpoint2
delay 150
show bitmap fixpoint3
delay 150
show bitmap fixpoint4
delay 150
###################################show 1 of 4 cues
if $cue == 1
show bitmap box_yellow -200 0
fi
if $cue == 2
show bitmap box_yellow 0 -200
fi
if $cue == 3
show bitmap box_yellow 200 0
fi
if $cue == 4
show bitmap box_yellow 0 200
fi
##################################################
readkey 1 $SOA # wait and ensure no key has been pressed
if STATUS != TIMEOUT
set $tooearly 1
show bitmap tooearlywarning
delay 1000
clear -1
fi
##################################################
# now show the target, but only if not too early
if $tooearly == 0
if $target == 1
show bitmap targetstim -200 0
set $expected_keynum 2
fi
if $target == 2
show bitmap targetstim 0 -200
set $expected_keynum 3
fi
if $target == 3
show bitmap targetstim 200 0
set $expected_keynum 4
fi
if $target == 4
show bitmap targetstim 0 200
set $expected_keynum 5
fi
#####################################################
readkey $expected_keynum 5000
clear -1 -2
######################################################################
# feedback
if STATUS == CORRECT
show bitmap happy
delay 500
clear -1
fi
if STATUS == WRONG
show bitmap sad
delay 500
clear -1
fi
if STATUS == TIMEOUT
show bitmap slow
delay 500
clear -1
fi
fi ## (from tooearly)
######################################################################
# intertrial interval
delay 500
save BLOCKNAME &training $cuetype $valid $SOA $waitkeytime $tooearly $cue $target STATUS RT
task endogenous ## with arrows
keys kp5 kp4 kp8 kp6 kp2
set $cuetype 1 # 1 = endo ; 2 = exo
set $tooearly 0
set $SOA random from 50 150 250 1000
## choose valid/invalid
set $valid random from 1 0 0 0 0 ## this means 20%
if $valid == 1 # if valid, cue and target are the same
set $cue random 1 4
set $target $cue
fi
if $valid == 0 # if not valid, cue and target must be different
set $cue random 1 4
set $target random 1 4
while $cue == $target
set $target random 1 4
while-end
fi
#############################################
show bitmap box_grey -200 0
show bitmap box_grey 0 -200
show bitmap box_grey 200 0
show bitmap box_grey 0 200
delay 100
show bitmap press5
readkey 1 50000
set $waitkeytime RT
clear -1
##############################################
show bitmap fixpoint1
delay 150
show bitmap fixpoint2
delay 150
show bitmap fixpoint3
delay 150
show bitmap fixpoint4
delay 150
###################################show 1 of 4 cues
if $cue == 1
show bitmap cue_left
fi
if $cue == 2
show bitmap cue_up
fi
if $cue == 3
show bitmap cue_right
fi
if $cue == 4
show bitmap cue_down
fi
##################################################
readkey 1 $SOA # wait and ensure no key has been pressed
if STATUS != TIMEOUT
set $tooearly 1
show bitmap tooearlywarning
delay 1000
clear -1
fi
##################################################
# now show the target, but only if not too early
if $tooearly == 0
if $target == 1
show bitmap targetstim -200 0
set $expected_keynum 2
fi
if $target == 2
show bitmap targetstim 0 -200
set $expected_keynum 3
fi
if $target == 3
show bitmap targetstim 200 0
set $expected_keynum 4
fi
if $target == 4
show bitmap targetstim 0 200
set $expected_keynum 5
fi
#####################################################
readkey $expected_keynum 5000
clear -1 -2
######################################################################
# feedback
if STATUS == CORRECT
show bitmap happy
delay 500
clear -1
fi
if STATUS != CORRECT
show bitmap sad
delay 500
clear -1
fi
if STATUS == TIMEOUT
show bitmap slow
delay 500
clear -1
fi
fi ## (from tooearly)
######################################################################
# intertrial interval
delay 500
save BLOCKNAME &training $cuetype $valid $SOA $waitkeytime $tooearly $cue $target STATUS RT
######################################################################
# blocks (this is really where the experiment starts
######################################################################
block numlocktest
message numlocktest
tasklist
numlocktester 8
end
message numlockconfirmation
block train_endo
pager instructions1 instructions2 instructions3 instructions4
message training_endo
set &training 1
tasklist
endogenous 50
end
block endo
set &training 0
message real_endo
tasklist
endogenous 100
end
block train_exo
set &training 1
message training_exo
tasklist
exogenous 50
end
block exo1
set &training 0
message real_exo
tasklist
exogenous 100
end
block exo2
set &training 0
message real_exo
tasklist
exogenous 100
end
feedback # as the final thing, we show feedback
text align left
set &EndoValid50 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 1 && c5 == 50 && c10 == 1
set &EndoValid150 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 1 && c5 == 150 && c10 == 1
set &EndoValid250 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 1 && c5 == 250 && c10 == 1
set &EndoValid1000 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 1 && c5 == 1000 && c10 == 1
set &EndoInvalid50 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 0 && c5 == 50 && c10 == 1
set &EndoInvalid150 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 0 && c5 == 150 && c10 == 1
set &EndoInvalid250 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 0 && c5 == 250 && c10 == 1
set &EndoInvalid1000 mean c11 ; select c2 == 0 && c3 == 1 && c4 == 0 && c5 == 1000 && c10 == 1
#
set &ExoValid50 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 1 && c5 == 50 && c10 == 1
set &ExoValid150 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 1 && c5 == 150 && c10 == 1
set &ExoValid250 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 1 && c5 == 250 && c10 == 1
set &ExoValid1000 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 1 && c5 == 1000 && c10 == 1
set &ExoInvalid50 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 0 && c5 == 50 && c10 == 1
set &ExoInvalid150 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 0 && c5 == 150 && c10 == 1
set &ExoInvalid250 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 0 && c5 == 250 && c10 == 1
set &ExoInvalid1000 mean c11 ; select c2 == 0 && c3 == 2 && c4 == 0 && c5 == 1000 && c10 == 1
#
text -300 -280 &EndoValid50 ; prefix "Valid endogenous Cues with SOA = 50: " ; postfix " ms"
text -300 -250 &EndoValid150 ; prefix "Valid Endogenous Cues with SOA = 150: " ; postfix " ms"
text -300 -220 &EndoValid250 ; prefix "Valid Endogenous Cues with SOA = 250: " ; postfix " ms"
text -300 -190 &EndoValid1000 ; prefix "Valid Endogenous Cues with SOA = 1000: " ; postfix " ms"
text -300 -160 &EndoInvalid50 ; prefix "Invalid Endogenous Cues with SOA = 50: " ; postfix " ms"
text -300 -130 &EndoInvalid150 ; prefix "Invalid Endogenous Cues with SOA = 150: " ; postfix " ms"
text -300 -100 &EndoInvalid250 ; prefix "Invalid Endogenous Cues with SOA = 250: " ; postfix " ms"
text -300 -70 &EndoInvalid1000 ; prefix "Invalid Endogenous Cues with SOA = 1000: " ; postfix " ms"
text -300 -40 &ExoValid50 ; prefix "Valid Exogenous Cues with SOA = 50: " ; postfix " ms"
text -300 -10 &ExoValid150 ; prefix "Valid Exogenous Cues with SOA = 150: " ; postfix " ms"
text -300 20 &ExoValid250 ; prefix "Valid Exogenous Cues with SOA = 250: " ; postfix " ms"
text -300 50 &ExoValid1000 ; prefix "Valid Exogenous Cues with SOA = 1000: " ; postfix " ms"
text -300 80 &ExoInvalid50 ; prefix "Invalid Exogenous Cues with SOA = 50: " ; postfix " ms"
text -300 110 &ExoInvalid150 ; prefix "Invalid Exogenous Cues with SOA = 150: " ; postfix " ms"
text -300 140 &ExoInvalid250 ; prefix "Invalid Exogenous Cues with SOA = 250: " ; postfix " ms"
text -300 170 &ExoInvalid1000 ; prefix "Invalid Exogenous Cues with SOA = 1000: " ; postfix " ms"
text -300 250 "PRESS SPACE BAR TO CONTINUE..."
end
Download
If you have a PsyToolkit account, you can upload the zipfile directly to your PsyToolkit account. Watch a video on how to do that. If you want to upload the zipfile into your PsyToolkit account, make sure the file is not automatically uncompressed (some browsers, especially Mac Safari, by default uncompress zip files). Read here how to easily deal with this. |
Further reading
-
Filoteo, J.V., Delis, D.C., Salmon, D.P., Demadura, T., Roman, M.J. & Shults, C. W. (1997). _Journal of the International Neuropsychological Society, 3, 337-347.