Group: Administrators
Posts: 13K,
Visits: 104K
|
You can select a random display (i.e. ink) color at the start of the block and then move on from there according to the *word* selected. A minimal example follows below:
<values> / displaycolor = 1 </values>
*** randomly select 1 out of 4 display colors at the start of the block *** <block myblock> / screencolor = (black) / onblockbegin = [values.displaycolor=noreplace(1,2,3,4); text.mytext.textcolor=list.displaycolor.nextvalue; ] / trials = [1-4=mytrial] </block>
*** at the end of the trial set display color for the next trial according to the *word* item selected in current trial *** <trial mytrial> / ontrialend = [values.displaycolor=text.mytext.currentindex; text.mytext.textcolor=list.displaycolor.nextvalue; ] / stimulusframes = [1=mytext] / validresponse = (57) / posttrialpause = 500 </trial>
<list displaycolor> / items = (red, green, blue, yellow) / selectionmode = values.displaycolor </list>
<text mytext> / items = myitems / fontstyle = ("Arial", 10%, true) / txbgcolor = (black) </text>
<item myitems> / 1 = "Red" / 2 = "Green" / 3 = "Blue" / 4 = "Yellow" </item>
|