Millisecond Forums

How to make each stimuli appear once in each trial type

https://forums.millisecond.com/Topic16331.aspx

By JayneP17s - 5/18/2015

Hello to all!

I have written a script for an attentional bias (visual probe) task. The participant is simultaneously shown two pictures, one food related and one neutral control. Then a probe will appear (an arrow) and their task is to indicate whether the arrow is pointing upwards or downwards. 

There are 128 trials and 16 unique trial types, each presented eight times. The 16 trial types are based upon the following 2x2x2x2 parameters: probe left/right, probe up/down, food picture high calorie/low calorie and probe behind the food picture/neutral control. Trials are presented randomly. I have 16 pairs of stimuli that are presented eight times across the experiment.

The question: I would like to amend my script so that each of the pair of stimuli is presented in each of the 16 trail types one time. At the moment each trial type is presented eight times, and each stimuli pair is presented eight times...but if I look at my data file, the file type7 might have used only six of the eight stimuli pairs and used two of them twice.

Here are excerpts from my script so you can see what I have done...

************************high_cal left up********
<trial 1>
/ validresponse = ("t", "v")
/ correctresponse = ("t")
/ inputdevice = keyboard
/ stimulustimes= [1 = fixation; 501 = blank; 502= high_cal_left, high_neu_right;  1002 = blank ; 1003 = probe1left]
/ timeout = 2500
</trial>

<block 3>
/ preinstructions = (maintask)
/ trials = [1-128 = random | noreplace (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16)]
</block>

Is there any way of making each stimuli appear only once in each trial type!? Any help would be very much appreciated!!! I will even write out all 128 trial combinations manually if I have to! (I'm just not sure how to do that).

Thanks in advance for all your help,
Jayne
By Dave - 5/18/2015

> Is there any way of making each stimuli appear only once in each trial type!?

There certainly is. But the code excerpts you posted do not speak to that question. What you need to look at is how items for the *stimulus* elements those trials present are selected.

I'd recommend reading through those two threads
https://www.millisecond.com/forums/Topic12480.aspx
https://www.millisecond.com/forums/Topic14239.aspx

particularly
https://www.millisecond.com/forums/FindPost12481.aspx
https://www.millisecond.com/forums/FindPost14400.aspx

regarding how to think about / conceptualize stimulus selection.
By JayneP17s - 5/19/2015

Hi Dave,

Thanks a lot for your reply. I can certainly see from the thread posts that my Inquisit script is doing exactly what I have told it to do - what I don't know is how to tell it what I want it to do. I have 128 unique stimulus-trial combinations and I want each one used once. I don't mind writing out all 128 stimulus-trail combinations - the problem is, as this is obviously long winded I can't find anywhere that tells me how to do this. All the sample scripts I've looked at don't do this and I can't work it out from previous thread posts.

Thanks a lot for your help,
Jayne
By Dave - 5/19/2015

Perhaps a simple example will help. Suppose you have four trial types t1 to t4 and 5 items A to E. You want each item to be displayed once in each trial type, yielding a total of 5 (items) x 4 (trial types) = 20 trials:

<values>
/ myvalue = 1
</values>

<block myblock>
/ trials = [1-20=noreplace(t1,t2,t3,t4)]
</block>

<trial t1>
/ ontrialbegin = [values.myvalue=list.t1items.nextindex]
/ stimulusframes = [1=mytext, trialname]
/ validresponse = (57)
</trial>

<trial t2>
/ ontrialbegin = [values.myvalue=list.t2items.nextindex]
/ stimulusframes = [1=mytext, trialname]
/ validresponse = (57)
</trial>

<trial t3>
/ ontrialbegin = [values.myvalue=list.t3items.nextindex]
/ stimulusframes = [1=mytext, trialname]
/ validresponse = (57)
</trial>

<trial t4>
/ ontrialbegin = [values.myvalue=list.t4items.nextindex]
/ stimulusframes = [1=mytext, trialname]
/ validresponse = (57)
</trial>

<text mytext>
/ items = myitems
/ select = values.myvalue
</text>

<item myitems>
/ 1 = "A"
/ 2 = "B"
/ 3 = "C"
/ 4 = "D"
/ 5 = "E"
</item>

<text trialname>
/ items = ("Current trial type: <%script.currenttrial%>")
/ position = (50%, 25%)
</text>

<list t1items>
/ poolsize = 5
</list>

<list t2items>
/ poolsize = 5
</list>

<list t3items>
/ poolsize = 5
</list>

<list t4items>
/ poolsize = 5
</list>