0 votes
24.9k views
by (320 points)
Hello,

I am running a 2AFC, in which two stationary gratings are drifting.

What is the best way to set the temporal frequency of the drift?

The task of the subject is to detect which of the gratings increased in temporal frequency. How do I increase the temporal frequency of one of the gratings with best timing accuracy?

Thank you

1 Answer

0 votes
by (14.5k points)
selected by
 
Best answer

The drifting animation in such task must be done in fixed time steps. While rendering of animation frames can naturally scripted in the Control Loop snippet, the control the frame times is not so easy, since rendering needs to be synchronized with monitor frames.

I would recommend to use a better approach by turning a recurrent event to a pacer for animation frames. To turn an event to the animation pacer you need to:

  • Add the recurrent time route to the event
  • Add animated stimuli in this event (for this case, 2 gratings)
  • Set the "Live rendering" property of the event to 'false' to prevent immediate visual updates
  • Implement the grating animation in 'After onset' snippet of the pacer event. Since event's live rendering is off, the visual changes on gratings will be presented only on the next event onset.
  • Finally, set the animation frame time by the duration of the pacer event. The duration of the pacer event has to be greater, than the frame rendering time. You can measure the actual rendering time for 2 gratings with the profiler.

To demonstrate this approach, I uploaded a 2AFC task here:

https://1drv.ms/u/s!Am6V32QsZzn5pkUBPQbJRFaV4IXQ

Note that the pacer event is located on the sub-layer of the Stimulus&Response event, which handles participant responses, while the pacer sub-event runs the animation at 60hz. The temporal frequency of gratings is defined by a phase shift for 1 animation frame.

 

 

 

Welcome to EventIDE Q&A forum where you can ask questions about EventIDE software and receive answers from other members of the community

Categories

FAQ questions

Installation and License


Coding


Eye-tracking


EEG Analysis


Visual Stimuli


Runtime and Data Collection


Hardware

...