To start - I know only the very basics of Python. This is my second time patchworking bits of code together that I’ve seen around!
The aim is to design an experiment that presents a stimulus that participants can respond to with one of two keys, ‘q’ or ‘p’. The stimulus presentation is looped to be presented five times. Response ‘q’ should only end the loop 1 in 5 times - for which they get a point. If three consecutive responses fail to end the loop then the ppt loses a point. Response ‘p’ should end the loop every time for which they get no points.
At the moment, the code I’ve written doesn’t end the loop at all based on key press - it runs through until it has cycled through all five presentations of the stimulus.
My guess is that the problem lies somewhere with the lines:
if response == ‘q’
if response == ‘p’
Hope someone can guide me in the right direction!
Thanks in advance