Thanks for that, it perfectly worked. I now still need to implement the exact same experiment in the builder (you can use your own repeat_loop.psyexp as a template for this), just with one difference: The loop needs to be repeated if it took the subject longer than 0.8 seconds to respond for at least two stimuli.
the code to insert in the checkAcc routine would be exactly the same as proposed by you
( if condition:
but the problem here is the coding of the condition. How can I access each specific reaction time of each stimulus? Then I could do sth like:
counter = 0
copy that into the Begin Experiment section of the code component of the checkAcc Routin
for x in trials.data[‘key_resp_2.rt’]:
if x > 0.8:
counter = counter + 1
if counter >= 2:
copy that into the Begin Routine Section of the code component of the checkAcc routine
But this code doesn’t work. You have an idea?