Start time as a variable

Hi all,

I am trying to assist with an experiment with varied start times. They have 2 sound files which need to start at different times when called. I have them set in the conditions file using the heading jitter, and the columns are filled with different start times,but using $jitter in the Start box does not work, as I am guessing it needs to be an integer?

Using $jitter in the expected start time also doesn’t start them at varied times.

Will I need to change the start times using a code component instead?

Best wishes

Jake

When you create a post in this forum, there is some default template text which includes this statement:

“That didn’t work” is not enough information.

i.e. You really need to describe the actual issue for us to be able to suggest how to solve it.

The “expected start time” field is purely informational/cosmetic - it allows Builder to graphically indicate a typical start time for the component when you aren’t providing a literal, fixed value for it. It has no role in the actual running of your experiment. You can even leave it blank if you like.

No, this sort of thing is entirely routine and exactly what components are designed to do. You just need to tell us exactly what you want to achieve, your actual problem (beyond “it doesn’t work”) and ideally show us a screenshot of the relevant component settings.

I totally understand your question and wonder whether anyone answered it. Where in the Builder stimulus interface do you enter that variable $jitter so that the start time of a stimulus is correctly read from a Conditions file? Because for me - entering $jitter in the Start Time for an event doesn’t make the stimulus start, ever, and when I compile the code from builder it is not acknowledged as a variable

Hi! I’m a student with a basic understanding of PsychoPy.

I wanted to achieve the same goal, to add jitter to the onset of a target in an experiment, and initially also tried to read this jitter in via an Excel conditions file. This did not start the stimulus at all (as was mentioned above).

I found that including ‘$normal(loc=1, scale=0.2)’ in the start box of the builder actually achieves this goal. I wanted the mean onset to be 1 second into the trial, but across trials the target should sometimes appear earlier and sometimes later. This function draws a random value from a normal distribution with mean = 1 and sd = 0.2.

I am still figuring out the specific values to use, but I believe this approach might help.

Also, there might be other (more efficient) ways to do this, but I did not find other solutions that worked in my specific case.

Kind regards

1 Like