【发布时间】:2020-02-18 14:43:20
【问题描述】:
我想在屏幕上显示刺激 1,如果做出特定的响应 1,则会显示刺激 2,然后用户需要按下特定键(响应 2),当他们这样做时,会显示刺激 3。我能够在呈现刺激 1 时根据响应 1 锻炼如何呈现刺激 2。但无法转移到刺激 3。我猜是因为我将它存储为“响应”,一旦它具有价值,它就不会再次更新?如何解决这个问题?提前致谢
%presenting text 1
Screen('DrawText',window,'stimuli1',xcen,ycen);
Screen('Flip',window)
%intiating keyboard
[keyIsDown, RTkeyCode] = KbWait;
r=find(RTkeyCode);%this should be the code for the key pressed
response=KbName(r);%Figure out what key strong text
Screen('TextSize',window,60)
Screen('DrawText',window,'question',xcen,ycen);
Screen('Flip',window)
WaitSecs(2)
if response=='b'
Screen('DrawText',window,'stmuli2',xcen,ycen)
Screen('Flip',window)
end
end
【问题讨论】:
标签: psychtoolbox