-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add keypad numbers to correct answer #53
base: main
Are you sure you want to change the base?
Conversation
Visit the preview URL for this PR (updated for commit 8e0a318): https://borton-task-msit--pr53-keypad-answer-hemeb0wc.web.app (expires Thu, 05 Aug 2021 17:40:04 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 |
probably not going to merge this before all the baylor stuff is done. |
@@ -116,17 +116,13 @@ export function rt_categorize_html() { | |||
|
|||
// create response function | |||
var after_response = function(info) { | |||
|
|||
// kill any remaining setTimeout handlers | |||
jsPsych.pluginAPI.clearAllTimeouts(); | |||
|
|||
// clear keyboard listener | |||
jsPsych.pluginAPI.cancelAllKeyboardResponses(); | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd also save the key_answer with the trial_data to be safe
|
||
// save data | ||
trial_data = { | ||
"rt": info.rt, | ||
"correct": correct, | ||
"stimulus": trial.stimulus, | ||
"key_press": info.key | ||
"key_press": info.key, | ||
"key_answer": trial.key_answer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mcmcgrath13 is this what you meant with the above comment?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yup!
The data json changes a bit with this.
The
code
field, which was 1,2,3 corresponding to the correct answer is gone, and that number is inkey_answer
now. Thekey_answer
from before, which was 48,49,50 corresponding to the right number key is also gone.