Millisecond Forums

calling on a sound item at two different during a trial

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

By Nick00004 - 2/3/2015

Hello,
I have a set of sound stimuli (each 10 seconds long) that need to be presented in a given trial, alongside a video, once at 10 seconds and again at 30 seconds. As I have it now, the audio comes on at the start of the trial, instead of at 10 seconds, and doesn't come back as it should. I'm thinking it's something obvious and to do with my /stimulustimes function, but I'm puzzled at the moment.
Here's the trial code (if you need more, I can include the rest):



<trial repeated.videos>
/ stimulustimes = [0 = videoclip; 20 = audioinstruction.repeated; 30 = audioinstruction.repeated]
/ validresponse = (anyresponse)
/ timeout = 40000
/ posttrialpause = 1000
</trial>
By Dave - 2/4/2015

The values in /stimulustimes are *milliseconds*, i.e., you're presenting the audio at 20 and 30 milliseconds into the trial, not 20 and 30 *seconds*.
By Nick00004 - 2/4/2015

Well, I'll be damned ... that just might be the most obvious solution to a "problem" .. thanks!
By Dave - 2/4/2015

Sometimes a fresh set of eyes helps -- things like these are easy to miss after staring at code for hours. :)
By Nick00004 - 2/4/2015

alas, it's not ready to be put to rest. I have one more creeping concern --
There are two general types of sound stimuli: non-repeating (18 different files to randomly select) and repeating (only one file). In repeated.videos trials I want the one sound stimulus to play at 10000 and repeated again at 30000; in the non-repeated.videos trials I want two different sound stimuli (randomly selected from the pool of 18) to come on, again, one at 10000 and another at 30000. Right now, in the non-repeated trials, the same sound file plays twice, rather than two different ones.  And in the repeated trials, it only plays once, at 10000, but not again at 30000.
I played around with different settings of the /select and /selectionrates functions, but same thing happens... here's the code:


Thanks!

###General purpose text and stimulus elements ###

<sound audioinstruction.nonrepeated>
/ items = AudioInstructionListNonRepeated
/ select = noreplacenorepeat
/ selectionrate = always
</sound>

<sound audioinstruction.repeated>
/ items = AudioInstructionListRepeated
/ select = replace
/ selectionrate = always
</sound>

###Trials ###

<trial repeated.videos>
/ stimulustimes = [0 = videoclip; 10000= audioinstruction.repeated; 20000 = audioinstruction.repeated]
/ validresponse = (anyresponse)
/ timeout = 40000
/ posttrialpause = 1000
</trial>

<trial nonrepeated.videos>
/ stimulustimes = [0 = videoclip; 10000 = audioinstruction.nonrepeated; 30000 = audioinstruction.nonrepeated]
/ validresponse = (anyresponse)
/ timeout = 40000
/ posttrialpause = 1000
</trial>

###Blocks###

<block block.repeated>
/ trials = [1=repeated.videos; 2=emotionratings]
</block>

<block block.nonrepeated>
/ trials = [1=nonrepeated.videos; 2=emotionratings]
</block>



By Dave - 2/4/2015

<sound audioinstruction.nonrepeated>
/ items = AudioInstructionListNonRepeated
/ select = noreplacenorepeat
/ selectionrate = always
</sound>

That won't work -- it's not how stimulus elements (are supposed to) behave. You need two <sound> elements sampling from the same item pool.

<sound audioinstruction.nonrepeated1>
/ items = AudioInstructionListNonRepeated
/ select = list.nonrepeatedlist.nextindex
</sound>

<sound audioinstruction.nonrepeated2>
/ items = AudioInstructionListNonRepeated
/ select = list.nonrepeatedlist.nextindex
</sound>

<list nonrepeatedlist>
...
/ selectionrate = always
</list>

<trial nonrepeated.videos>
/ stimulustimes = [0 = videoclip; 10000 = audioinstruction.nonrepeated1; 30000 = audioinstruction.nonrepeated2]
/ validresponse = (anyresponse)
/ timeout = 40000
/ posttrialpause = 1000
</trial>