|
Post by skaiste on Mar 29, 2021 7:52:05 GMT
Dear all, I need to alternate two types of task (which differ in stimulus list to be randomly presented), but can not find how to count remainder for defining odd and even trials. Modulo operator works only with surveys.
task typeAtypeB set $typeA random 1 8 set $typeB random 1 8 while $typeA == &previoustyppeA || $typeB == &previoustypeB set $typeA random 1 8 set $typeB random 1 8 while-end set &previoustypeA $typeA set &previoustypeB $typeB set $typeBbitmap expression $typeB + 8 #refer to bitmaps from 9 to 16 keys a l set $oddeven expression (TRIALCOUNT - 2 * integer(TRIALCOUNT / 2)) if $oddeven == 0 set %stimulus $typeA else set %stimulus $typeB fi show text %stimulus 0 0 white save KEY RT STATUS
|
|