Commit Graph

297 Commits

Author SHA1 Message Date
Josh de Leeuw
8d2211b712 Add error message if plugin is not loaded
Closes #51
2014-06-24 12:07:57 -04:00
Josh de Leeuw
12c527e0b4 typo fix in core.submitToTurk 2014-06-16 09:44:51 -04:00
Josh de Leeuw
ebfc6548f6 Add core.submitToTurk
* add function to core
* modify turkInfo to also grab turkSubmitTo location (either sandbox or production)
2014-06-15 12:56:03 -04:00
Josh de Leeuw
decd0cf04b add jsPsych.totalTime method
gets the total time in ms since the experiment started.
2014-06-11 23:15:17 -04:00
Josh de Leeuw
b3b82db7f8 add class information to display element
related to issue #45
2014-06-11 16:10:35 -04:00
Josh de Leeuw
c0beee3221 handle multiple parameters with single call of enforce array 2014-05-19 10:42:14 -04:00
Josh de Leeuw
c5539da1a6 Merge branch 'master' into smart-arrays
Conflicts:
	jspsych.js
2014-05-19 10:05:58 -04:00
Josh de Leeuw
ab6c105dd1 make sure unprocessed functions get preserved in trial obj
related to issue #42
2014-05-15 14:25:33 -04:00
Josh de Leeuw
a8f2a676e6 Allow for protected variables in normalizeTrialVariables
Related to #43
2014-05-14 15:13:04 -04:00
Josh de Leeuw
c88c07887c PreloadImages method will auto-flatten the input array
Closes #42
2014-05-13 13:02:47 -04:00
Josh de Leeuw
75dc0e8b57 Adding enforceArray method 2014-04-28 16:47:15 -04:00
Josh de Leeuw
c8cb4204d1 adding normalizeTrialVariables method
method takes an object (intended to be a trial data structure) and converts any function arguments to their returned value.
2014-03-03 10:41:24 -05:00
Josh de Leeuw
1a3ca8cc69 Add option to return flattened data object
Related to issue #31 because it moves a utility function into the core library.
2014-02-28 17:07:07 -05:00
Josh de Leeuw
99e7cb58ba Adding an extra value for identifying when page is loaded outside of Turk context (relevant to #10) 2013-11-21 15:08:20 -05:00
Josh de Leeuw
b6a89b935c Adding jsPsych.turkInfo() method (addresses issue #10) 2013-11-20 15:07:32 -05:00
Josh de Leeuw
a04f33f30e adding core.preloadImages() 2013-11-11 23:09:21 -05:00
Josh de Leeuw
1f173bcea4 tweaking saveAstext 2013-11-09 19:59:27 -05:00
Josh de Leeuw
d28108d175 tweaking saveAstext 2013-11-09 19:51:45 -05:00
Josh de Leeuw
68a7b64c66 tweaking saveAstext 2013-11-09 19:49:25 -05:00
Josh de Leeuw
61b4a07fa6 bug fix savecsv to file 2013-11-09 17:07:33 -05:00
Josh de Leeuw
fa447f0f52 bug fix savecsv to file 2013-11-09 17:05:29 -05:00
Josh de Leeuw
9bb65c1f1b bug fix savecsv to file 2013-11-09 17:01:03 -05:00
Josh de Leeuw
c820e18f7c adding save CSV to disk option in core library 2013-11-09 16:47:30 -05:00
Josh de Leeuw
260de7bbff fixing a bug in the CSV method 2013-11-07 18:55:49 -05:00
Josh de Leeuw
8da176ec73 adding CSV data option to core library 2013-11-07 18:49:58 -05:00
Josh de Leeuw
9e5c7d73f9 bug fix core - adding root document element addition by default 2013-11-04 10:36:05 -05:00
Josh de Leeuw
f671d6f8da bug fix core 2013-10-26 22:43:46 -04:00
Josh de Leeuw
1facd91a9b changing how display_element is set in the core library 2013-10-24 16:26:26 -04:00
Josh de Leeuw
94af5d0d7b minor typo fix jspsych.js 2013-10-22 12:44:45 -04:00
Josh de Leeuw
f50a579834 add on_data_update callback function to core 2013-10-21 18:00:26 -04:00
Josh de Leeuw
c33eec8724 add on_data_update callback function to core 2013-10-21 18:00:13 -04:00
Josh de Leeuw
d5598e3fff v1.08
- added adaptive category training
- categorize multi and samedifferentloc are incomplete and untested
- fixed issue with core file that caused failure when init method was
called twice.
2013-01-14 11:01:14 -05:00
Josh de Leeuw
fc6321de8a minor commenting 2012-09-06 16:35:05 -04:00
Josh de Leeuw
871ba7a897 added jspsych-free-sort
free sort is a plugin that displays a set of stimuli and records the
movements that participants make as they drag the stimuli to sort them.
sorting is unconstrained (i.e. there are no specific groups that
participants are told to sort into).
2012-07-19 14:18:50 -04:00
Josh de Leeuw
2f0d6c7e1e bug fix - moved where on_trial_finish is called to ensure it is called at the end of every trial 2012-07-17 18:49:46 -04:00
Josh de Leeuw
946f1aeea0 bug fixes for callback methods in previous commit 2012-07-17 18:13:52 -04:00
Josh de Leeuw
19983090a8 Added optional callback methods for tiral start and trial finish events in core library.
Can now pass in functions to the core library on init() so that a
function can be called at the start or end of every trial.
2012-07-17 18:05:09 -04:00
Josh de Leeuw
b33ab88b22 Added core.progress
// core.progress returns an object with the following properties
//   total_blocks: the number of total blocks in the experiment
//  total_trials: the number of total trials in the experiment
//  current_trial_global: the current trial number in global terms
//      i.e. if each block has 20 trials and the experiment is
//     currently in block 2 trial 10, this has a value of 30.
//  current_trial_local: the current trial number within the block.
//  current_block: the current block number.

Useful for showing user progress through the experiment. Planning to add
an option to show a progress bar in the future.
2012-07-17 17:51:17 -04:00
Josh de Leeuw
39846f1754 recommit of previous commit since nothing was changed...
jspsych-similarity.js : fixed data storage so that generic data object
was included in the block's data.

jspsych-storybook.js: included generic data object in data storage,
included path to image in data storage.

jspsych.js: cosmetic adjustment to code in finishExperiment() method.

NEW:

added call-function plugin, which calls a user-specified function.
useful for saving data before completion.

added paint plugin - displays a canvas element superimposed on an image
and allows subjects to draw on the image to indicate areas of interest.
2012-07-12 13:22:06 -04:00
Josh de Leeuw
3c04677878 added core.data()
jsPsych.data() now returns an array that contains all of the data from
the experiment.
2012-07-05 12:30:36 -04:00
Josh de Leeuw
338a21d199 breaking change
changes to the core jspsych.js file will break some backwards
compatibility. script files are no longer loaded dynamically, due to
issues with using $.getScript on local installations. this revision
makes defining a list of plugins unnecessary; they are automatically
recognized based on the experiment structure.

changes to similarity plugin: display is now sequential.

adding storybook plugin: this is an ipad plugin, which displays a single
image and records the location of touch events.
2012-06-29 13:16:24 -04:00
Josh de Leeuw
befdcfc1cd Rescoped everything so that jsPsych is not a jQuery plugin.
The top level object is jsPsych, and plugins are defined as jsPsych.PLUGIN.

The library also loads everything dynamically now, so the user only needs to load the main jsPsych script (and specify the src for any plugins).

This also changes how the library is loaded initially, since it is not based on the jQuery method anymore. See wiki.
2012-05-17 09:19:04 -04:00
Josh de Leeuw
9c94b4d0b6 Reworking the plugin structure to use the Module javascript design pattern.
Plugins now have a consistent internal structure, with better variable scoping.

This version breaks backward compatibility due to a change in the syntax of how experiment objects are declared.
2012-05-15 16:03:26 -04:00
Josh de Leeuw
9c8884f356 removed showImage and showImages from jspsych.js
fixed ie bugs in similarity
2012-05-14 15:41:15 -04:00
Josh de Leeuw
e88a1b052f Suite of bugfixes and changes related to same-different and animation plugin. Animation plugin is a complete redesign that removes dependency on the canimate.js library. 2012-04-05 14:00:20 -04:00
Josh de Leeuw
dfb0642ec2 verifying git setup 2012-03-30 10:15:53 -04:00
Drew Hendrickson
ee8de223d5 code directly from Josh 2012-03-26 23:32:21 -04:00