undoing trials_3.map

parent e30fcbda
......@@ -693,11 +693,11 @@ function embedded_formRoutineEnd(trials) {
thisComponent.setAutoDraw(false);
}
});
showSlider = psychoJS.experiment._trials_3Data.map((trial) => trial['showSlider']);
showLoop = psychoJS.experiment._trials_3Data.map((trial) => trial['showLoop']);
showAge = psychoJS.experiment._trials_3Data.map((trial) => trial['showAge']);
showVideo = psychoJS.experiment._trials_3Data.map((trial) => trial['showVideo']);
showSeed = psychoJS.experiment._trials_3Data.map((trial) => trial['showSeed']);
showSlider = psychoJS.experiment._trialsData.map((trial) => trial['showSlider']);
showLoop = psychoJS.experiment._trialsData.map((trial) => trial['showLoop']);
showAge = psychoJS.experiment._trialsData.map((trial) => trial['showAge']);
showVideo = psychoJS.experiment._trialsData.map((trial) => trial['showVideo']);
showSeed = psychoJS.experiment._trialsData.map((trial) => trial['showSeed']);
// the Routine "embedded_form" was not non-slip safe, so reset the non-slip timer
routineTimer.reset();
......@@ -717,11 +717,11 @@ function random_seedRoutineBegin(trials) {
frameN = -1;
// update component parameters for each repeat
msg = ((("Testing reseeding random numbers.\n\nrandomnum1: " + randomnum1.toString()) + "\n\nrandomnum2: ") + randomnum2.toString());
console.log(showSlider[0]);
console.log(showLoop[0]);
console.log(showAge[0]);
console.log(showVideo[0]);
console.log(showSeed[0]);
console.log(showSlider.slice((- 1))[0]);
console.log(showLoop.slice((- 1))[0]);
console.log(showAge.slice((- 1))[0]);
console.log(showVideo.slice((- 1))[0]);
console.log(showSeed.slice((- 1))[0]);
instructions.setText((msg + '\n\nPress space to continue'));
// keep track of which components have finished
......
......@@ -696,11 +696,11 @@ function embedded_formRoutineEnd(trials) {
thisComponent.setAutoDraw(false);
}
}
showSlider = psychoJS.experiment._trials_3Data.map((trial) => trial['showSlider']);
showLoop = psychoJS.experiment._trials_3Data.map((trial) => trial['showLoop']);
showAge = psychoJS.experiment._trials_3Data.map((trial) => trial['showAge']);
showVideo = psychoJS.experiment._trials_3Data.map((trial) => trial['showVideo']);
showSeed = psychoJS.experiment._trials_3Data.map((trial) => trial['showSeed']);
showSlider = psychoJS.experiment._trialsData.map((trial) => trial['showSlider']);
showLoop = psychoJS.experiment._trialsData.map((trial) => trial['showLoop']);
showAge = psychoJS.experiment._trialsData.map((trial) => trial['showAge']);
showVideo = psychoJS.experiment._trialsData.map((trial) => trial['showVideo']);
showSeed = psychoJS.experiment._trialsData.map((trial) => trial['showSeed']);
// the Routine "embedded_form" was not non-slip safe, so reset the non-slip timer
routineTimer.reset();
......@@ -720,11 +720,11 @@ function random_seedRoutineBegin(trials) {
frameN = -1;
// update component parameters for each repeat
msg = ((("Testing reseeding random numbers.\n\nrandomnum1: " + randomnum1.toString()) + "\n\nrandomnum2: ") + randomnum2.toString());
console.log(showSlider[0]);
console.log(showLoop[0]);
console.log(showAge[0]);
console.log(showVideo[0]);
console.log(showSeed[0]);
console.log(showSlider.slice((- 1))[0]);
console.log(showLoop.slice((- 1))[0]);
console.log(showAge.slice((- 1))[0]);
console.log(showVideo.slice((- 1))[0]);
console.log(showSeed.slice((- 1))[0]);
instructions.setText((msg + '\n\nPress space to continue'));
// keep track of which components have finished
......
......@@ -458,8 +458,8 @@
<CodeComponent name="code">
<Param name="Begin Experiment" updates="constant" val="" valType="extendedCode"/>
<Param name="Begin JS Experiment" updates="constant" val="" valType="extendedCode"/>
<Param name="Begin JS Routine" updates="constant" val="msg = (((&quot;Testing reseeding random numbers.\n\nrandomnum1: &quot; + randomnum1.toString()) + &quot;\n\nrandomnum2: &quot;) + randomnum2.toString());&amp;#10;console.log(showSlider[0]);&amp;#10;console.log(showLoop[0]);&amp;#10;console.log(showAge[0]);&amp;#10;console.log(showVideo[0]);&amp;#10;console.log(showSeed[0]);&amp;#10;" valType="extendedCode"/>
<Param name="Begin Routine" updates="constant" val="msg=&quot;Testing reseeding random numbers.\n\nrandomnum1: &quot;+str(randomnum1) + &quot;\n\nrandomnum2: &quot;+str(randomnum2)&amp;#10;&amp;#10;print(showSlider[0])&amp;#10;print(showLoop[0])&amp;#10;print(showAge[0])&amp;#10;print(showVideo[0])&amp;#10;print(showSeed[0])" valType="extendedCode"/>
<Param name="Begin JS Routine" updates="constant" val="msg = (((&quot;Testing reseeding random numbers.\n\nrandomnum1: &quot; + randomnum1.toString()) + &quot;\n\nrandomnum2: &quot;) + randomnum2.toString());&amp;#10;console.log(showSlider.slice((- 1))[0]);&amp;#10;console.log(showLoop.slice((- 1))[0]);&amp;#10;console.log(showAge.slice((- 1))[0]);&amp;#10;console.log(showVideo.slice((- 1))[0]);&amp;#10;console.log(showSeed.slice((- 1))[0]);&amp;#10;" valType="extendedCode"/>
<Param name="Begin Routine" updates="constant" val="msg=&quot;Testing reseeding random numbers.\n\nrandomnum1: &quot;+str(randomnum1) + &quot;\n\nrandomnum2: &quot;+str(randomnum2)&amp;#10;&amp;#10;print(showSlider[-1])&amp;#10;print(showLoop[-1])&amp;#10;print(showAge[-1])&amp;#10;print(showVideo[-1])&amp;#10;print(showSeed[-1])" valType="extendedCode"/>
<Param name="Code Type" updates="None" val="Auto-&gt;JS" valType="str"/>
<Param name="Each Frame" updates="constant" val="keys = event.getKeys(['space','quit'], waitRelease=True)&amp;#10;if 'quit' in keys:&amp;#10; core.quit()&amp;#10;elif 'space' in keys or showSeed != 1:&amp;#10; continueRoutine=False&amp;#10; &amp;#10;" valType="extendedCode"/>
<Param name="Each JS Frame" updates="constant" val="var _pj;&amp;#10;function _pj_snippets(container) {&amp;#10; function in_es6(left, right) {&amp;#10; if (((right instanceof Array) || ((typeof right) === &quot;string&quot;))) {&amp;#10; return (right.indexOf(left) &gt; (- 1));&amp;#10; } else {&amp;#10; if (((right instanceof Map) || (right instanceof Set) || (right instanceof WeakMap) || (right instanceof WeakSet))) {&amp;#10; return right.has(left);&amp;#10; } else {&amp;#10; return (left in right);&amp;#10; }&amp;#10; }&amp;#10; }&amp;#10; container[&quot;in_es6&quot;] = in_es6;&amp;#10; return container;&amp;#10;}&amp;#10;_pj = {};&amp;#10;_pj_snippets(_pj);&amp;#10;keys = event.getKeys([&quot;space&quot;, &quot;quit&quot;], {&quot;waitRelease&quot;: true});&amp;#10;if (_pj.in_es6(&quot;quit&quot;, keys)) {&amp;#10; core.quit();&amp;#10;} else {&amp;#10; if ((_pj.in_es6(&quot;space&quot;, keys) || (showSeed !== 1))) {&amp;#10; continueRoutine = false;&amp;#10; }&amp;#10;}&amp;#10;" valType="extendedCode"/>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment