Commit Graph

396 Commits

Author SHA1 Message Date
Ari Dyckovsky
183c6a6d65 Patch to graceful failure on DataCollection.first and .last
Reason:
- Expected behavior by experimenter to avoid crashing by throw exception

Changes made:
- Tightened up logic statements and returned array directly without
  shallow copy first

Notes:
- Issue #751 and #748
2020-08-14 13:47:27 -06:00
Ari Dyckovsky
9da4bb23d0 Graceful failure on DataCollection.first and .last
Reason:
- When n > number of trials, or nonpositive, failure caused crashing

Changes made:
- Update each .first and .last methods to return when n is within range,
  while throwing an error when it is not.
- Use Array.prototype.slice to create subarrays

Notes:
- Issue #751 and #748
- Unsure of precise goal for graceful failure. Should it throw an error
  create a dummy array of some length?
2020-08-13 23:22:35 -06:00
Vijay Marupudi
4057fc8d88 Fixed undefined type check with typo 2020-04-09 12:05:39 -05:00
Rui Han
a5650993ed
Variable name error? 2020-01-29 16:02:24 -05:00
Josh de Leeuw
87571e9cc9 fixes #659 2019-10-17 15:46:26 -04:00
Josh de Leeuw
b4ca37be1c implement experiment_width #572 2019-07-11 10:21:50 -04:00
Josh de Leeuw
d120b3b470 implement alternating groups sample method (#528) 2019-07-08 21:53:40 -04:00
Josh de Leeuw
5172e6dddc add shuffleAlternateGroups #528 2019-07-08 11:35:25 -04:00
Josh de Leeuw
5cd95bcb7e fixes default iti bug (#632) 2019-07-08 10:26:28 -04:00
Josh de Leeuw
b4bfb1852d fixes timeline vars in conditional functions #574 2019-07-05 11:43:40 -04:00
Josh de Leeuw
eafa1d3269 fixes #628 2019-07-02 11:47:59 -04:00
Josh de Leeuw
355eae8be2 add error message for randomization module (#389) 2019-06-19 10:14:29 -04:00
Josh de Leeuw
b850debcae fixes #391 2019-06-18 12:02:17 -04:00
Josh de Leeuw
6356341944 remove old comment todo 2019-06-18 11:38:22 -04:00
Josh de Leeuw
8eb344fbf1
Merge pull request #609 from retowyss/patch-1
Enable language option for progress bar
2019-06-03 16:47:16 -04:00
Josh de Leeuw
05461d7949 change .variance and .sd to samples (#601) 2019-05-30 17:04:09 -04:00
Josh de Leeuw
4a5a310e79 fixes #597 2019-05-24 17:26:42 -04:00
Josh de Leeuw
7686082446 tentative fix for #603; need to add testing 2019-05-24 15:26:29 -04:00
Reto Wyss
9a1714fbe2
Enable language option for progress bar 2019-04-12 06:23:14 +02:00
Josh de Leeuw
bc03aebfb1 allow functions in data params (#562) 2018-12-14 12:12:50 -05:00
Josh de Leeuw
e59895cb8e updates for video preloading 2018-10-12 11:48:01 -04:00
Josh de Leeuw
b551f99f12
Merge branch 'master' into master 2018-10-12 11:19:51 -04:00
Josh de Leeuw
501a5be52a update all to performance.now() - #492 2018-10-09 16:13:59 -04:00
Josh de Leeuw
6eeed765af make default progress bar amount 0 2018-10-09 13:51:24 -04:00
Josh de Leeuw
954eac9784 fix progress bar bug 2018-10-09 13:47:43 -04:00
Josh de Leeuw
6a6d390cb8 add get of progress bar value (#538) 2018-10-09 13:21:53 -04:00
Josh de Leeuw
59258d3215 implements #324 -- beforeunload event handler 2018-10-09 13:12:07 -04:00
Josh de Leeuw
330e5a8611 add preventDefaul on captured key responses #548 2018-10-04 15:23:34 -04:00
Josh de Leeuw
299e9d7671 fix focus #563 2018-10-04 14:04:54 -04:00
Josh de Leeuw
7a08072070 scroll to top of DOM target at start of next trial #550 2018-10-04 13:55:08 -04:00
Dillon Plunkett
da094d8a30 make shuffleNoRepeats check last two elements 2018-09-14 19:57:34 -04:00
Josh de Leeuw
6eb7ec21ac fix #557 by removing 0s, nulls, and false values from preload arrays 2018-08-15 09:46:57 -04:00
andy
6409d23620 min RT feature, working 2018-07-02 14:35:49 +01:00
andy
cb1071df43 min RT feature, working 2018-07-02 14:02:12 +01:00
andy
9c6e5f292c min RT feature 2018-07-01 20:29:31 +01:00
andy
07cd15dbca preload video + non-preloaded video ability 2018-06-30 20:45:30 +01:00
Josh de Leeuw
2970c94559 fixes #539 2018-06-25 21:33:39 -04:00
Josh de Leeuw
0f92127a49 fixes #541 by moving current_trial_finished to better location 2018-06-25 15:33:29 -04:00
andy
22bd4961d4 working preloaded video 2018-05-31 09:56:42 +01:00
andy
5a6b20f695 untested preload video mod 2018-05-30 20:55:21 +01:00
Josh de Leeuw
442fe05ed9 fixes chrome 66+ audio play #518 2018-05-14 22:24:19 -04:00
Josh de Leeuw
b4a0ce33e6 fix docs, make callback optional #513 2018-04-17 10:43:37 -04:00
Josh de Leeuw
2f568aebdb patch a bug with multiple init calls and webaudio context 2018-03-20 12:27:42 -04:00
Josh de Leeuw
3fb7ef6b6d fix loadFail timeout bug 2018-02-18 16:53:31 -05:00
Josh de Leeuw
2c172a1caf add a small delay between preload reattempts, documentation #503 2018-02-18 16:24:04 -05:00
Josh de Leeuw
f3d5a5043d make webaudio optional #508 2018-02-18 16:19:09 -05:00
Josh de Leeuw
7fa09da61f max_preload_attempts #503 2018-02-10 15:12:17 -05:00
Josh de Leeuw
c4a7f090d8 starts on #503 2018-02-10 15:10:33 -05:00
Josh de Leeuw
49aba8ee08 fix bug with null values 2018-01-11 10:11:13 -05:00
Josh de Leeuw
f7966aeaf1 implements #489 2018-01-03 13:57:20 -05:00
Josh de Leeuw
051c0839bf add on_load function #486 2017-12-28 16:06:31 -05:00
Josh de Leeuw
906f43376b implements on_start #483 2017-12-08 21:13:38 -05:00
Josh de Leeuw
fcc8878e37 add complex parameter type 2017-07-26 15:17:12 -04:00
Josh de Leeuw
c08d2f1df2 add polyfill for Array.isArray 2017-07-22 12:35:02 -04:00
Josh de Leeuw
12dcd30ad9 better deepCopy util 2017-07-21 22:11:19 -04:00
Josh de Leeuw
d21dea8b9a add universalPluginParameters 2017-07-19 13:13:42 -04:00
Josh de Leeuw
624c8d6f8b use default values when param=null 2017-07-14 23:31:47 -04:00
Josh de Leeuw
09ccb196bf HMTL -> HTML 2017-07-14 10:17:54 -04:00
Josh de Leeuw
805e74e3b6 make keycodes case insensitive 2017-07-13 11:25:11 -04:00
Josh de Leeuw
691f1c076d remove unnecessary console.log 2017-07-12 14:33:33 -04:00
Josh de Leeuw
5d888912f9 starts #432 2017-07-12 09:58:27 -04:00
Josh de Leeuw
f36b85092d remove trial level display element option 2017-07-12 09:37:25 -04:00
Josh de Leeuw
6970926460 fix platform fn.toString bug 2017-07-11 22:35:28 -04:00
Josh de Leeuw
756c88a07f better timing parameter names #425 2017-07-10 14:00:24 -04:00
Josh de Leeuw
8f19625c6b testing for new method of evaluation function params #426 2017-07-10 10:55:00 -04:00
Josh de Leeuw
7a6b72f88d more testing repairs 2017-07-09 23:52:42 -04:00
Josh de Leeuw
d3e06db3a4 fix bug to avoid checking type parameter 2017-07-09 23:32:01 -04:00
Josh de Leeuw
31e1fc190b removing pluginAPI.evaluateFunctionParameters #426 2017-07-09 23:05:04 -04:00
Josh de Leeuw
c372efe1d1 locate evaluation of function parameters inside jsPsych core #426 2017-07-09 21:15:59 -04:00
Josh de Leeuw
d7282a228e bug fix for reset GUI 2017-07-06 15:26:46 -04:00
Josh de Leeuw
e0c14ca403 better reset for GUI 2017-07-06 15:26:45 -04:00
KristinDiep
1d0742e676 split iat plugin 2017-07-06 13:59:09 -04:00
Josh de Leeuw
caca99335d clarify parameter type #423 2017-07-06 09:54:05 -04:00
Josh de Leeuw
2a39ad4a2a split sample method; add weights option for timeline variables sampling 2017-07-05 16:55:35 -04:00
Josh de Leeuw
acce4407e5 fixes #406 2017-06-25 22:50:05 -04:00
Josh de Leeuw
5ec449c0f6 bug fix for reset GUI 2017-06-21 12:11:32 -04:00
Josh de Leeuw
08a3166cc6 better reset for GUI 2017-06-21 12:04:13 -04:00
Josh de Leeuw
e4cd1bb151 don't add class name redundantly 2017-06-21 11:43:40 -04:00
Josh de Leeuw
c739dfcb3b add new sampling option, fixes #398 2017-06-20 11:40:05 -04:00
Josh de Leeuw
9810dab604 fixes #387 with proper focus 2017-06-19 14:46:17 -04:00
Josh de Leeuw
91c67f8688 add auto_update_progress_bar property to jsPsych.init 2017-06-10 21:31:59 -04:00
Josh de Leeuw
4184913b1e fixes #387 2017-06-07 22:44:33 -04:00
Josh de Leeuw
ac4bb0a818 cap range of setProgressBar #325 2017-06-01 15:47:04 -04:00
Josh de Leeuw
b09384929f add setProgressBar #325 2017-06-01 15:37:43 -04:00
Josh de Leeuw
f6adf2f8af adjust #384 style 2017-05-30 10:01:36 -04:00
Josh de Leeuw
934f394de0 first pass at #384 2017-05-27 18:09:28 -04:00
Josh de Leeuw
d287f7a4d3 fixes #343 2017-05-25 11:17:56 -04:00
Josh de Leeuw
6b53fced9d reset variables when timeline loops #343 2017-05-25 10:51:08 -04:00
Josh de Leeuw
a0ecd6dc23 only preload unique files; fixes #377 2017-05-25 10:40:59 -04:00
Josh de Leeuw
41f6f4d8ed fix .unique bug 2017-05-25 10:38:55 -04:00
Josh de Leeuw
25b4f28f40 move utility functions to .utils module for better testing 2017-05-25 10:33:23 -04:00
Josh de Leeuw
6dc62aec0e remove fullscreen from jsPsych.init #380 2017-05-24 22:18:16 -04:00
Josh de Leeuw
5ad4e4c9a4 implement #349 2017-03-19 16:38:59 -04:00
Josh de Leeuw
f941731a5b #334 add data collection method .uniqueNames 2017-02-04 16:05:22 -05:00
Josh de Leeuw
065fd8d4b0 change jsPsych.data.getData() to jsPsych.data.get() 2017-02-02 16:47:35 -05:00
Josh de Leeuw
12043f2ffc Merge pull request #289 from rivasd/parallelport
Changes for supporting parallel port triggers with our Chrome extension
2017-01-18 12:55:52 -05:00
Josh de Leeuw
ba356b6588 change execution order of finishExperiment 2017-01-17 15:07:23 -05:00
Rob Wilkinson
15016febc6 cleaned up console logs 2017-01-13 17:49:27 -08:00
Xiaolu Bai
467dcb0460 bugfix_multiple_choice_module 2017-01-13 01:57:04 -08:00
Josh de Leeuw
f40214066b pretty print json; fix #318; adjust timelineVaribale to return function by default 2017-01-12 14:43:38 -05:00