Reputation: 13
I am tring to create a task were right or left oriented gabor is presented at the middle of the screen. Then 'right' is a correct key for the right-oriented gabor, and 'left' for the left-oriented one. When I use the loopType (in trials Properties):
I apologize for these probably very basic questions, but I am just starting with programming. I would be very happy if someone could help me with this staircase.
Upvotes: 1
Views: 885
Reputation: 1223
When you add a response option, like a Keyboard Component that supports the option of Storing Correct and, when you tick that box you can specify what the correct answer should be on this trial (a variable with value matching a key name). See the demos, like stroop task, where we set a correct answer key.
So then the question is how to make your stimulus come up in different orientations and connect that to a particular response. You could do this with a single staircase (from what you've told us so far) not interleaved ones and then you'd need a code component in your trial that did something like this in the Begin Routine code section:
if random()>0.5: # 50:50 probability
ori = 45
corrAns = 'left'
else:
ori = -45
corrAns = 'right'
# store the info we created in the data file
trials.addOtherData('corrAns', corrAns)
trials.addOtherData('ori', ori)
Then set your keyboard response to treat $corrAns
to detect correct response
Upvotes: 1