Post by nickzamby on Jun 4, 2021 3:33:40 GMT
Hi everyone,
I hope you are doing well. I'm somewhat new to PsyToolKit, but I wouldn't say I'm a complete beginner (I know some basics of R).
I've run into a bit of a problem with my Navon experiment, specifically adding a 20 second 'rest-period' after a series of 36 trials. This rest period contains a stimulus "20 second break" (bitmap rest) and delay of 20000 ms (task rest), but I've struggled to put my thoughts into code. Essentially, I am asking 1) what have I done wrong? 2) how can I adjust my current code to fit what I'd like? 3) how can I repeat this so I reach a total number of 360 stimuli per experiment?
Just to summarize, I wouldd like my experiment to flow:
1. 36 randomly selected stimuli from bitmaps (navon task), followed by...
2. 20 second 'rest-period' that shows bitmap rest
3. repeat these tasks so that I have a total of 360 stimuli shown, but every 36 stimuli, there's a rest period.
Below you can find my code (I've bolded my point of error)...
options
bitmapdir stimuli
bitmaps
Hh
Hh2
Ho
Hs
Ht
Oo
Oo2
Oh
Os
Ot
Ss
Ss2
Sh
So
St
Tt
Tt2
Th
To
Ts
correct
wrong
tooslow
instructions1
instructions2
instructions3
rest
fonts
arial 18
table navon
"Hs dif 0" Hs 1
"Hh same 1" Hh 2
"Hh2 same 1" Hh 2
"Ho dif 0" Ho 1
"Ht dif 0" Ht 1
"Oo same 1" Oo 2
"Oo2 same 1" Oo 2
"Os dif 0" Os 1
"Oh dif 0" Oh 1
"Ot dif 0" Ot 1
"Tt same 1" Tt 2
"Tt2 same 1" Tt 2
"Ts dif 0" Ts 1
"Th dif 0" Th 1
"To dif 0" To 1
"Ss same 1" Ss 2
"Ss2 same 1" Ss 2
"Sh dif 0" Sh 1
"St dif 0" St 1
"So dif 0" So 1
task navon
table navon
keys d s
show bitmap @2
readkey @3 625
if STATUS == CORRECT
show bitmap correct
fi
if STATUS == WRONG
show bitmap wrong
fi
if STATUS == TIMEOUT
show bitmap tooslow
fi
delay 500
clear 1 2
delay 500
save @1 STATUS RT
task rest
show bitmap rest
delay 20000
block my_block
message instructions1
message instructions2
message instructions3
delay 1000
tasklist
navon 36 all_before_repeat
rest 1
end
feedback
text color yellow
text align left
set &DifRT mean c5 ; select c3 == 0
set &SameRT mean c5 ; select c3 == 1
set &AvgRT mean c5
set &PureRT mean c5 ; select c4 == 1 && c4 == 2
set &DifC count ; select c3 == 0 && c4 == 1
set &SameC count ; select c3 == 1 && c4 == 1
set &Correct count ; select c4 == 1
set &DifW count ; select c3 == 0 && c4 == 2
set &SameW count ; select c3 == 1 && c4 == 2
set &Incorrect count ; select c4 == 2
set &TooSlow count ; select c4 == 3
text -200 -200 "Feedback Navon task"
text -200 -150 "Reaction Times per experimental condition:"
text -200 -100 &DifRT ; prefix "Different RT: " ; postfix " ms"
text -200 -50 &SameRT ; prefix "Same RT:" ; postfix " ms"
text -200 0 &AvgRT ; prefix "Average RT:" ; postfix " ms"
text -200 50 &PureRT ; prefix "Pure RT:" ; postfix "ms"
text -200 250 "press space bar to continue"
end
feedback
text -200 -150 "Correct count per experimental condition:"
text -200 -100 &DifC ; prefix "Different Stimuli: " ; postfix " correct"
text -200 -50 &SameC ; prefix "Same Stimuli:" ; postfix " correct"
text -200 0 &Correct ; prefix "Total Correct:" ; postfix " correct"
text -200 250 "press space bar to continue"
end
feedback
text -200 -150 "Incorrect count per experimental condition:"
text -200 -100 &DifW ; prefix "Different Stimuli:" ; postfix " incorrect"
text -200 -50 &SameW ; prefix "Same Stimuli:" ; postfix " incorrect"
text -200 0 &Incorrect ; prefix "Total Incorrect:" ; postfix " incorrect"
text -200 50 &TooSlow ; prefix "Too Slow:" ; postfix " stimuli"
text -200 250 "press space bar to continue"
end
THANK YOU!
Nick
I hope you are doing well. I'm somewhat new to PsyToolKit, but I wouldn't say I'm a complete beginner (I know some basics of R).
I've run into a bit of a problem with my Navon experiment, specifically adding a 20 second 'rest-period' after a series of 36 trials. This rest period contains a stimulus "20 second break" (bitmap rest) and delay of 20000 ms (task rest), but I've struggled to put my thoughts into code. Essentially, I am asking 1) what have I done wrong? 2) how can I adjust my current code to fit what I'd like? 3) how can I repeat this so I reach a total number of 360 stimuli per experiment?
Just to summarize, I wouldd like my experiment to flow:
1. 36 randomly selected stimuli from bitmaps (navon task), followed by...
2. 20 second 'rest-period' that shows bitmap rest
3. repeat these tasks so that I have a total of 360 stimuli shown, but every 36 stimuli, there's a rest period.
Below you can find my code (I've bolded my point of error)...
options
bitmapdir stimuli
bitmaps
Hh
Hh2
Ho
Hs
Ht
Oo
Oo2
Oh
Os
Ot
Ss
Ss2
Sh
So
St
Tt
Tt2
Th
To
Ts
correct
wrong
tooslow
instructions1
instructions2
instructions3
rest
fonts
arial 18
table navon
"Hs dif 0" Hs 1
"Hh same 1" Hh 2
"Hh2 same 1" Hh 2
"Ho dif 0" Ho 1
"Ht dif 0" Ht 1
"Oo same 1" Oo 2
"Oo2 same 1" Oo 2
"Os dif 0" Os 1
"Oh dif 0" Oh 1
"Ot dif 0" Ot 1
"Tt same 1" Tt 2
"Tt2 same 1" Tt 2
"Ts dif 0" Ts 1
"Th dif 0" Th 1
"To dif 0" To 1
"Ss same 1" Ss 2
"Ss2 same 1" Ss 2
"Sh dif 0" Sh 1
"St dif 0" St 1
"So dif 0" So 1
task navon
table navon
keys d s
show bitmap @2
readkey @3 625
if STATUS == CORRECT
show bitmap correct
fi
if STATUS == WRONG
show bitmap wrong
fi
if STATUS == TIMEOUT
show bitmap tooslow
fi
delay 500
clear 1 2
delay 500
save @1 STATUS RT
task rest
show bitmap rest
delay 20000
block my_block
message instructions1
message instructions2
message instructions3
delay 1000
tasklist
navon 36 all_before_repeat
rest 1
end
feedback
text color yellow
text align left
set &DifRT mean c5 ; select c3 == 0
set &SameRT mean c5 ; select c3 == 1
set &AvgRT mean c5
set &PureRT mean c5 ; select c4 == 1 && c4 == 2
set &DifC count ; select c3 == 0 && c4 == 1
set &SameC count ; select c3 == 1 && c4 == 1
set &Correct count ; select c4 == 1
set &DifW count ; select c3 == 0 && c4 == 2
set &SameW count ; select c3 == 1 && c4 == 2
set &Incorrect count ; select c4 == 2
set &TooSlow count ; select c4 == 3
text -200 -200 "Feedback Navon task"
text -200 -150 "Reaction Times per experimental condition:"
text -200 -100 &DifRT ; prefix "Different RT: " ; postfix " ms"
text -200 -50 &SameRT ; prefix "Same RT:" ; postfix " ms"
text -200 0 &AvgRT ; prefix "Average RT:" ; postfix " ms"
text -200 50 &PureRT ; prefix "Pure RT:" ; postfix "ms"
text -200 250 "press space bar to continue"
end
feedback
text -200 -150 "Correct count per experimental condition:"
text -200 -100 &DifC ; prefix "Different Stimuli: " ; postfix " correct"
text -200 -50 &SameC ; prefix "Same Stimuli:" ; postfix " correct"
text -200 0 &Correct ; prefix "Total Correct:" ; postfix " correct"
text -200 250 "press space bar to continue"
end
feedback
text -200 -150 "Incorrect count per experimental condition:"
text -200 -100 &DifW ; prefix "Different Stimuli:" ; postfix " incorrect"
text -200 -50 &SameW ; prefix "Same Stimuli:" ; postfix " incorrect"
text -200 0 &Incorrect ; prefix "Total Incorrect:" ; postfix " incorrect"
text -200 50 &TooSlow ; prefix "Too Slow:" ; postfix " stimuli"
text -200 250 "press space bar to continue"
end
THANK YOU!
Nick