This article is currently being updated by our staff.
This example illustrates how to write the contents of a List object to a text (.txt) file. The contents of this text file are then read into another experiment to determine the order of trials in that experiment.
E-Basic script is used to create and open a text file in Output mode. The Subject and Session number are used in the name of the text file so that the Participant can enter the same credentials during the following experiment.
The trials are then randomized in an array object and the first half of the trials are ran. If there are an odd number of trials is in the TrialList, integer division is used to always make the second List section have one more trial than the first.
In the ReadRandomWord experiment(.es2) file, the contents of the text file are read into the experiment. The order of the trails presented in the experiment will then exactly match the order of trials in the text file.
This method of reading and writing the contents of a List object are most commonly used in instances of pseudo randomization where the degrees of freedom for any given presentation of stimuli are relatively low. This sample can also be used in test-retest and within subjects types of experiments.