Skip to content
Discussion options

You must be logged in to vote

Hi @dusannikolic92, are you seeing any errors in the JavaScript console when you run your task on cognition.run? Also, what version of jsPsych did you select on cognition.run? I ask because I noticed that this line:

if (data.correct_response == jsPsych.pluginAPI.convertKeyCodeToKeyCharacter(data.key_press)) {

won't work in v6.3+ because the key_press property in the trial data was changed to response. In v6.3 we also switched to using key characters (e.g. 'f', 'j') in the data, rather than numeric key codes. So instead of using the jsPsych.pluginAPI.convertKeyCodeToKeyCharacter function, you would use jsPsych.pluginAPI.compareKeys to check the response accuracy. So altogether, the line ab…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by dusannikolic92
Comment options

You must be logged in to vote
1 reply
@becky-gilbert
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants