generated from psych251/rescue_template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
949ac93
commit 1434db9
Showing
1 changed file
with
23 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,15 +8,23 @@ | |
<script src="https://unpkg.com/@jspsych/[email protected]">/* Button plugin */</script> | ||
<script src="https://unpkg.com/@jspsych/[email protected]">/* Preload plugin */</script> | ||
<script src="https://unpkg.com/@jspsych/[email protected]">/* Instructions plugin */</script> | ||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js">/* jQuery Library for proliferate data collection */</script> | ||
<script src="https://proliferate.alps.science/static/js/proliferate.js" type="text/javascript">/* Proliferate data collection plugin */</script> | ||
<link href="https://unpkg.com/[email protected]/css/jspsych.css" rel="stylesheet" type="text/css" /> | ||
</head> | ||
<body></body> | ||
<script> | ||
/* Initialize jsPsych */ | ||
var jsPsych = initJsPsych({ | ||
on_finish: function() { | ||
// jsPsych.data.displayData('csv'); | ||
jsPsych.data.get().localSave( 'csv','pilotA_data.csv'); | ||
on_finish: function(data) { | ||
// DISPLAY RESPONSES IN BROWSER AFTER EXPERIMENT | ||
// jsPsych.data.displayData('csv'); | ||
|
||
// DOWNLOAD RESPONSES AS .CSV FILE AFTER EXPERIMENT | ||
// jsPsych.data.get().localSave( 'csv','pilotA_data.csv'); | ||
|
||
// COLLECT RESPONSES IN PROLIFERATE | ||
proliferate.submit({"trials": data.values()}); | ||
} | ||
}); | ||
|
||
|
@@ -187,6 +195,17 @@ | |
show_progress_bar: true | ||
}; | ||
|
||
/* | ||
------------------------------------------ | ||
ADD SUBJECT_ID IN PROLIFIC DATA | ||
------------------------------------------*/ | ||
|
||
var subject_id = jsPsych.data.getURLVariable('PROLIFIC_PID'); | ||
|
||
jsPsych.data.addProperties({ | ||
subject_id: subject_id | ||
}); | ||
|
||
/* | ||
------------------------------------------- | ||
WELCOME AND INSTRUCTIONS | ||
|
@@ -410,7 +429,7 @@ | |
|
||
var contact_msg = { | ||
type: jsPsychHtmlButtonResponse, | ||
stimulus: `<p> Thank you for completing the experiment. Please email for [email protected] any questions or concerns. </p>`, | ||
stimulus: `<p> Thank you for completing the experiment. Please email [email protected] for any questions or concerns. </p>`, | ||
choices: [ 'Finish'] | ||
}; | ||
|
||
|