Creating Text and Picture Stimuli

The first step in building an experiment is to define all of the stimuli. Stimuli include text or pictures to be shown on a given trial, background text that remains on the screen throughout a block of trials, or a feedback text shown to the subject to indicate when to respond and whether their response was correct or incorrect.

Inquisit allows you to specify global default settings for stimuli and other parts of the experiment using the <defaults> element. For this script, we will set the default font for all text stimuli that we present, and we'll also set the background color for the screen to black.

<defaults>
/ screencolor = (0, 0, 0)
/ fontstyle = ("Arial", 20pt)
</defaults>

Now, let's create the arrow stimuli to be presented at the fixation point in the center of the screen:

<picture leftarrow>
/ items = ("http://www.millisecond.com/download/library/covertattention/leftarrow.jpg")
</picture>

<picture rightarrow>
/ items = ("http://www.millisecond.com/download/library/covertattention/rightarrow.jpg")
</picture>

That was pretty easy. We simply created two picture stimuli called "leftarrow" and "rightarrow". Both stimuli consist of a single item picture item contained in the picture files "rightarrow.jpg" and "lefttarrow.jpg" respectively. In this case, the files are downloaded from http://www.millisecond.com/samples/covertattention, but typically you would keep the files in the same folder as the script. By default, Inquisit presents the pictures in the center of the screen.

Now, let's define a text stimulus to serve as the fixation point itself.

<text fixation>
/ items = ("+")
/ color = (255, 255, 255)
/ txbgcolor = (0,0,0)
/ fontstyle = ("Arial", 30pt)
/ erase = false
</text>

The text is called "fixation" and it consists of a single item, "+". The foreground color is white, with the red, green, and blue values set to the maximum value of 255. You can use Inquisit's Color Wizard available on the Tools menu to get the red, green, and blue values for any color. The background color is black, with red, green, and blue values set to the minimum value of 0. The font is Arial. You can select a font using Inquisit's Font Wizard, also available on the Tools menu. Finally, the erase command indicates that the fixation point should not be erased.

Now, let's define text stimuli to be presented just below the fixation point that will serve as instruction reminders.

<text instructleft>
/ items = ("Press A if the brightened box is on the left.")
/ position = (50, 60)
/ color = (255, 255, 255)
/ txbgcolor = (0,0,0)
</text>

<text instructright>
/ items = ("Press S if the brightened box is on the right.")
/ position = (50, 65)
/ color = (255, 255, 255)
/ txbgcolor = (0,0,0)
</text>

The instruction stimuli use the position command to present the stimuli just below the fixation point. Position is specified in terms of x and y coordinates. The unit of measurement is percentage, with 0 = top/left, 50 = center, and 100 = bottom right. The instruction reminders are presented horizontally centered and vertically 10 percentage points below center.

Now, let's define the target pictures. We will create four target stimuli, each of which presents a picture of a light yellow rectangle in one of the four corners of the screen.

<picture toplefttarget> 
/ items = ("http://www.millisecond.com/download/library/covertattention/targetrectangle.jpg") 
/ position = (0, 0)
/ valign = top 
/ halign = left 
</picture>

<picture bottomlefttarget> 
/ items = ("http://www.millisecond.com/download/library/covertattention/targetrectangle.jpg") 
/ position = (0, 100) 
/ valign = bottom 
/ halign = left 
</picture> 

<picture toprighttarget> 
/ items = ("http://www.millisecond.com/download/library/covertattention/targetrectangle.jpg") 
/ position = (100, 0) 
/ valign = top 
/ halign = right 
</picture> 

<picture bottomrighttarget> 
/ items = ("http://www.millisecond.com/download/library/covertattention/targetrectangle.jpg") 
/ position = (100, 100) 
/ valign = bottom 
/ halign = right 
</picture> 

Finally, we'll create the distractor stimuli. There are four distractors, each of which presents a dark yellow rectangle in the four corners of the screen.

<picture topleft> 
/ items = ("http://www.millisecond.com/download/library/covertattention/rectangle.jpg") 
/ position = (0, 0) 
/ valign = top 
/ halign = left 
</picture> 

<picture bottomleft> 
/ items = ("http://www.millisecond.com/download/library/covertattention/rectangle.jpg") 
/ position = (0, 100) 
/ valign = bottom 
/ halign = left 
</picture> 

<picture topright> 
/ items = ("http://www.millisecond.com/download/library/covertattention/rectangle.jpg") 
/ position = (100, 0) 
/ valign = top 
/ halign = right 
</picture> 

<picture bottomright> 
/ items = ("http://www.millisecond.com/download/library/covertattention/rectangle.jpg") 
/ position = (100, 100) 
/ valign = bottom 
/ halign = right 
</picture> 

Those are all the stimuli that we'll present in this script. Next, we'll create the instructions.


Overview Creating Instructions