FAQ

Questions:
 
1.  How can I determine the duration of the stimulus portion of my grating stimulus in the NewStim system?
2.  I know the temporal frequency and duration I want for my grating stimulus; how many cycles should I use?
 
Answers:
 
1.  How can I determine the duration of the stimulus portion of my grating stimulus in the NewStim system?

The grating stimuli are periodic and will run at a given temporal frequency (tFrequency) for a particular number of cycles (nCycles), and, optionally, loop forwards and backwards according to the parameter loops (0 means only loop forward, 1 means loop forward then backward, 2 means loop forward then backward then forward, etc).  The formula for the duration (in seconds) is approximately (loops+1)*nCycles/tFrequency.

2.  I know the temporal frequency and duration I want for my grating stimulus; how many cycles should I use?

The answer depends if you want the stimulus to loop forward and backwards (okay for measuring orientation responses but not direction responses) or just forwards (okay for measuring direction or orientation responses).  If you want to loop forward then backwards once, set loops to 1.  If you want to only loop forward, set loops to 0.  Then set nCycles = desired_duration * tFrequency/(loops+1).  This has to be an integer, so you may need to round the value of this formula.
Comments