![]() Remember to set the loop in Builder to be in a fixed order, not randomised, as the list itself has the randomisation built in. Then just write the images list to a single column. # remove this combination so it can't be used again Images.append('face_' + currentFace + '_emotion_' + currentEmotion + '.jpg') PsychoPy ® is a free cross-platform package allowing you to run a wide range of experiments in the behavioral sciences (neuroscience, psychology, psychophysics, linguistics.). The trialHandler presents a predetermined list of conditions in either a sequential or random (without replacement) order. # find another pair with the same selected attribute: This is what underlies the random and sequential loop types in Builder, they work using the method of constants. # next 24 randomised but balanced choices: # need to create an initial selection before cycling though the Begin Routine: m圜ount m圜ount + 1 if m圜ount > 10: trials.finished True Note In Python there is no end to finish an if statement. # a list of whether to alternate between preserving face or emotion across trials:Īttributes = * 12 # length 24 # make a list of 25 dictionaries of unique face/emotion pairs:įor emotion in : ![]() ![]() you also need a list of pseudo-random choices to alternate between preserving either face or emotion from trial to trial: if you do this fully randomly, you'll get unbalanced, and exhaust one of the attributes before the other. It will need 8 columns: 7 to specify the unique images in a trial and an eighth to specify the repeated one. First, start with your conditions file (i.e.csv or. You'll need to create three lists, not two, i.e. 1 Answer Sorted by: 0 Yes, you're correct that there is a (much) more efficient way to do this. You'd just insert a code component with some code to run at the beginning of the experiment that customises a conditions file. It could simply be: if not rr: trials5.finished True. That way you could do everything in PsychoPy, and in this case there would be no need to abandon Builder. So instead to randomizing newlist, randomize cuelist. You have not yet randomized filler and stimuli. ![]() But it could also very easily be implemented in Python code. There is no need to set the loop type to random. That would work fine, as this stuff can be done before PsychoPy even launches. The standard answer to this is what you allude to in your comment above: in code, shuffle the conditions file at the beginning of each experiment, so each subject is in essence having their trials driven by a unique conditions file. Although the order of rows can be randomised across subjects, the pairings of values across columns remains constant. This is difficult to implement in Builder's normal mode of operation, which is to drive trials from a fixed list of conditions. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |