ABSTRACT

The targettime variable we opened up at the start of the script will be used to record the time of target presentation on each trial. Remember that this variable is currently defined as a column of 0s, one for each trial (see Step 2). The new command

at line 42 updates the existing targettime variable by replacing the 0 that represents the current trial (trialcount) with the time value returned by GetSecs immediately after the target is presented on-screen. As the program runs, this will happen for every iteration of the for loop, each time the target is presented. At the end of the experiment, the targettime variable will therefore finish up as a column of numbers reflecting the time in seconds of target presentation on every trial.