Skip to content

waitStimEnd

Experiments

waitStimEnd makes the response window wait for the end of the stimulus. Its main use is audio/video trials: keep responses (and per-screen trial text) disabled until the media file finishes playing, regardless of what responseWindow says about the start position.

Put 1 in the cell of every trial where responses should wait for the stimulus to finish. Any non-empty value switches the behavior on; there is no special value grammar. Leave the cell empty to keep it off.

ValueBehavior
empty cellOff
any other value (1, yes, true, even 0)On. Even 0 ACTIVATES the feature (only an empty cell is treated as off)

When the column is absent or the cell is left empty, the feature is off: the response window opens wherever responseWindow says, and on audio/video trials any trial text appears at playback start.

  • responseWindow: setting waitStimEnd forces the response window to open when the stimulus ends, discarding any start position from responseWindow but keeping its timeout. So responseWindow of 2000 plus waitStimEnd of 1 means the window opens when the stimulus ends, then closes 2000 ms later with a recorded timeout response and auto-advance.
  • Audio/video trials: responses and per-screen trial text are held back until the last media file finishes playing. During playback, per-screen trial text stays hidden unless trialTextOptions contains allStim, allTrial or withStim.
  • Image/word trials: the override applies here too, so waitStimEnd on a non-media trial simply behaves like a responseWindow of afterStim (the window opens after the last screen’s presTime). The media-specific trial-text deferral does not apply.
  • type of learn: media learn trials auto-advance when playback ends and never open a response window.
typestim1stimFormatwaitStimEndkeyboardkey
teststory_clip.mp31y,ny

The y/n keys do nothing while the mp3 plays; the response window opens the moment playback ends and stays open until a response.

typestim1stimFormatwaitStimEndresponseWindowbutton1button2
testad_video.mp413000LikeDislike

Buttons appear only when the video finishes; after 3000 more ms without a click the trial records timeout and advances (timeout preserved through the override).

  • With waitStimEnd set, responseWindow position tokens (withStim, allTrial, numeric start times) are silently ignored; only a numeric timeout survives.
  • Combining waitStimEnd with a responseWindow that already contains afterStim is harmless: the window still opens once, when the stimulus ends.