PennController for IBEX › Forums › Support › Big dataset: how to handle?
- This topic has 4 replies, 2 voices, and was last updated 2 years, 7 months ago by
andrealistanti.
-
AuthorPosts
-
March 20, 2023 at 2:56 pm #10401
andrealistantiParticipantHi, I am programming an experiment about word recognition. The experiment is very simple: we have a long list of words and pseudowords, a hundred of them (67 words, 33 pseudowords) are shown on the screen one at a time and the participants have to respond whether they know them or not.
PC Ibex picks a random sample of words and pseudowords from the list via the function “pick”:
function Pick(set,n) { assert(set instanceof Object, "First argument of pick cannot be a plain string" ); n = Number(n); if (isNaN(n) || n<0) n = 0; this.args = [set]; set.remainingSet = null; this.run = function(arrays){ if (set.remainingSet===null) set.remainingSet = arrays[0]; const newArray = []; for (let i = 0; i < n && set.remainingSet.length; i++) newArray.push( set.remainingSet.shift() ); return newArray; } } function pick(set, n) { return new Pick(set,n); }In the sequence, I specify the number of words and pseudowords I want to get picked:
rshuffle(pick(randomize("words"),67),pick(randomize("pseudowords"),33))The problem is that the full dataset has 32400 words and 10921 pseudowords. The current code works only up to a total of ca. 5000. If I try to use the full dataset I get this message: “Range error: maximum call stack size ecceded”.
Is there a way to solve the problem?
Many thanks!
Andrea
March 21, 2023 at 9:24 am #10404
JeremyKeymasterHi Andrea,
Would you mind sharing a link to your study? I cannot seem to reproduce the problem myself
Jeremy
March 22, 2023 at 11:29 am #10410
andrealistantiParticipantMarch 23, 2023 at 5:18 am #10414
JeremyKeymasterHi Andrea,
That link is invalid. If you create a new project to share, make sure to do so while logged in, so it can be saved in your account; projects created while logged out are automatically deleted 30 minutes after their last edit
Jeremy
March 26, 2023 at 6:11 pm #10423
andrealistantiParticipantDear Jeremy,
thanks a lot for your reply and for your help, and sorry about the link. In the meantime I managed to solve the problem, so for the moment I do not need to bother you. Thanks a lot!Andrea
-
AuthorPosts
- You must be logged in to reply to this topic.