Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Push instructions into the jsPsych timeline:

Code Block
languagejs
/* Instructions #1 */
var instructions_1 = {
    type: jsPsychHtmlButtonResponse,
    stimulus: '<div style="width: 800px;">' +
        '<h2>Visual <i>N</i>-Back Task Demonstration</h2>' +
        '<p>This will test your ability to hold information in short-term, temporary memory. This is called working memory.</p>' +
        '</div>',
    choices: ["Continue"]
}
timeline.push(instructions_1);
/* Instructions #2 */
var instructions_2 = {
    type: jsPsychHtmlButtonResponse,
    stimulus: '<div style="width: 800px;">' +
        '<p>You will see a sequence of letters presented one at a time. Your task is to determine if the letter on the screen matches ' +
        'the letter that appeared two letters before.</p>' +
        '<h4>If the letters match, press the M key.</h4>' +
        '<p>For example, if you saw the sequence X, C, V, B, V, X you would press the M key when the second V appeared on the screen.</p>' +
        '<h4>Do not press any key when there is not a match.</h4>' +
        '</div>',
    choices: ["Continue"]
}
timeline.push(instructions_2);
/* Instructions #3 */
var instructions_3 = {
    type: jsPsychHtmlKeyboardResponse,
    stimulus: '<div style="width: 800px;">' +
        '<p>The sequence will begin on the next screen.</p>' +
        '<p>Remember: press the M key if the letter on the screen matches the letter that appeared two letters ago.</p>' +
        '<p>When you are ready to begin, press the M key to begin</p>' +
        '</div>',
    choices: ["M"],
    post_trial_gap: 1000
}
timeline.push(instructions_3);

...