|
Post by lenalala on Aug 29, 2022 13:34:41 GMT
Hey everyone, I'm new here and have a question... I was trying to design an experiment where, depending on the condition, a participant is in (according to their passcodes), I want the participants to watch one of two clips (according to their group). I tried creating the conditions with a table, typing in the participants-codes in the first row and the condition in the second, trying to use "readkeys" and "if"-statements to show the respecitve videos, but that didn't work out... Does anyone have an idea what I can do instead or how to improve my coding? Thank you for your answers! My code: table participants "001" 1 "002" 2 "003" 1 "004" 2 "005" 1 "006" 2 "007" 1 task film show text "Type in the participant's number." 0 -200 show rectangle 0 0 20 20 0 255 0 readkeys option size 3 readkeys option placeholders 30 30 readkeys @1 60000 clear screen delay 1000 keys space show bitmap start readkey 1 60000 if @2 == 1 show video a delay 9000 fi if @2 == 2 show video b delay 9000 fi
|
|
|
Post by wooders on Sept 1, 2022 2:12:50 GMT
When I have done conditions, I use the jump function. This is set at random of three conditions. I suppose you could assign still but PsyToolkit will even set to ensure equal groups now.
l: condition t: set - random 1 3
l: t: jump - if $condition = 1 then goto TSposFeedback - if $condition = 2 then goto TSnegFeedback - if $condition = 3 then goto TSnoFeedback
l: TSposFeedback t: experiment - TSposFeedback
l: t: jump - goto
......
|
|