-
Hello everyone, I'm new to jsPsych. I wonder how to present a short audio (such as the sound "Di", lasting for 500ms) at a random point of time during the presentation of a text (such as a sentence) ?? Now I can noly present a sentence and a sound separately. The audio-keyboard-response plugin and the prompt parameter for displaying text cannot resolve my issue of randomly present an audio during the text presentation. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Two options that I can think of:
|
Beta Was this translation helpful? Give feedback.
Two options that I can think of:
You could modify the audio-keyboard-response plugin to add a parameter that delays the start of the audio. If you know how to do this in JavaScript it will be a fairly straightforward modification to the plugin. Feel free to post here for help with this if you go that route.
You could break the trial into two parts. You can use an html-keyboard-response trial to display the text by itself, using
trial_duration
to control the length of the random interval. If you setpost_trial_gap: 0
then the transition should be seamless from the perspective of the subject.