User`s guide

E-Prime User’s Guide
Chapter 3: Critical Timing
Page 77
Intended and Actual Display Duration -
Without E-Prime
0
100
200
300
400
500
600
700
800
900
1000
1 26 51 76 101 126 151 176
Image number
Display Duration (ms)
Intended
Session 1
Session 2
Figure 1. Actual display durations for displays run on 2 sessions relative to the intended (200ms) duration.
The program’s task is simple -- display each image for 200ms while the microsecond clock is
being read. How could the timing be that far off and erratic? It is important to understand why
this might happen in a program or experiment that you believe to be correct. This will help you to
recognize it when it occurs, and to set features in E-Prime to avoid it.
The program specified that images stored on the disk are to be displayed for 200ms each. In
order to accomplish this the computer, read the image data from the disk, prepared the image for
presentation, copied the image to the display screen, waited 200ms, and then started the cycle
again for the next image presentation. The time to read the image from disk, prepare it for
presentation and copy it to the screen required a median time of 105ms. Thus, the median total
time for the image display is 105ms (setup time), plus the specified display duration of 200ms, for
a total of 305ms. This is an illustration of the problem: It is not possible for the computer to put up
a display without preparation and thus some amount of “setup time”. Therefore to correct the
problem, the next display must be setup while the subject is looking at the current display.
E-Prime introduces the concept of using PreRelease time to address this problem. This facility
allows the current stimulus to release a portion of its execution time to a following stimulus in
order to allow the following stimulus to perform setup activities (e.g., read the data from disk and
get the image ready in memory). Then, at the scheduled time for the following stimulus, the
display is already prepared, and it is simply copied to the screen. By overlapping the setup time
for the following display with the duration of the current display, the delay caused by the setup
time can be reduced and potentially eliminated. If the PreRelease time allotted is greater than the
setup time required, the images can be loaded and presented without delay. In this example, a
PreRelease time of 150ms would provide ample time for setup, and there would be no added
variability.