Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

collect spaces and if run statement

Hi,

I am working on an event segmentation experiment in OpenSesame (running online via JATOS/Prolific) and I have two questions.

Question 1: Tracking spacebar presses during video playback

I want participants to press the spacebar whenever they perceive an event boundary while watching a video. I need to collect all spacebar presses during the video (not just one), log the timestamp of each press in milliseconds relative to the video start, and have these saved in the logfile per trial. I currently have an inline JavaScript item playing the video. What is the best way to collect and log these keypresses in OSWeb with accurate millisecond timing aligned to the video?

Question 2: Attention check after every 3rd video not working

I have an attention check inside my trial sequence that is meant to verify whether participants have actually watched the video. It consists of a sketchpad (showing a question about the video) and a text input where participants have to write their answer. I want this attention check to appear after every 3rd video. I am using a video_count variable that increments by 1 after each video ends, and I set the run-if condition on both items to:

video_count % 3 == 0 and video_count > 0

However the attention items never appear at all. I am currently using a sketchpad for the question display but I am not sure if that is the right item type for this. Is there something specific about how run-if conditions work in OSWeb that I am missing, and is there a better way to trigger an attention check with a text input field every N trials in OSWeb?


Thanks in advance.

Sign In or Register to comment.