// @author Philipp A Schroeder - philipp.schroeder@uni-tuebingen.de // always happy to hear if you could use this plugin or made any contribution ! :) jsPsych.plugins['jspsych-primeprobe'] = (function(){ var plugin = {}; plugin.trial = function(display_element, trial){ /* general structure is: - fixate - flankers - target - response window - ITI - fixate - flankers 2 - target 2 - response window 2 - end */ trial.text_answer = (typeof trial.text_answer === 'undefined') ? "" : trial.text_answer; trial.correct_text = (typeof trial.correct_text === 'undefined') ? "
" : trial.correct_text; trial.incorrect_text = (typeof trial.incorrect_text === 'undefined') ? "Fehler.
" : trial.incorrect_text; trial.timeout_message = trial.timeout_message || "Bitte schneller reagieren.
"; trial.timing_flankers = trial.timing_stim || -1; // default is to show image until response trial.timing_targets = trial.timing_stim || -1; // default is to show image until response trial.timing_response = trial.timing_response || 2000; trial.timing_feedback_duration = trial.timing_feedback_duration || 2000; /* library of elements display_element.append('This is the first paragraph
'); display_element.append('This is the second paragraph
'); // clear the display display_element.html(''); */ var data = { correct: true, rt: 350 } var data2 = { correct: true, rt: 350 } jsPsych.finishTrial(data1, data2); } return plugin; })();