The correctResponse attribute specifies the set of responses considered correct for a given trial.
<defaults> <checkboxes> <dropdown> <image> <listbox> <radioButtons> <slider> <textbox> <trial> <likert> <openended> <sliderTrial>
or
/ correctResponse = (scancode, scancode, ...)or
/ correctResponse = (anyResponse, noResponse, ...)or
/ correctResponse = (stimulusname, stimulusname, ...)or
/ correctResponse = (mouseevent, mouseevent, ...)or
/ correctResponse = (gamepadstickevent, gamepadevent, ...)or
/ correctResponse = (joystickevent, joystickevent, ...)or
/ correctResponse = (word, word, ...)or
/ correctResponse = (response)or
/ correctResponse = (expression, expression, ...)Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
character | string | A character indicating a correct keyboard response. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
scancode | integer | An integer specifying the scancode of a correct keyboard response. See the scancodes table for corresponding key value assignments. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
mouseevent | mouseeventenum |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
gamepadevent | gamepadeventenum |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
joystickevent | joystickeventenum |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
response | responseenum |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
stimulusname | visualstimulus | The name of a stimulus element defined elsewhere in the script. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
word | string | A string (in quotes) indicating a correct spoken or openended response. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
response | responseenum |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
expression | value | An expression that resolves to response value. |
This attribute specifies an array of responses considered correct for this trial. Responses specified in correctResponse are automatically considered valid responses and need not also be specified in validResponse. Inquisit uses this attribute to determine whether the subject's response was correct for a given trial so that the error feedback can be given if necessary and to determine whether the value (0 or 1) should written to the "correct" column of the data file. The syntax of the settings depends on the type of input device used (e.g., mouse, keyboard, voice) as defined by the inputDevice attribute.
For all input devices, "noResponse" can be specified to indicate that the absence of a response should be considered a correct response. This setting can be used in conjunction with the timeout attribute to implement "go/no go" tasks.
For voice and openended input, the correctResponse can be set to a stimulus name, in which case the currently selected item in that stimulus is considered a correct response. This is useful for naming or recall tasks where the correct response is determined by whatever stimulus item is currently presented.
For mouse input, the correctResponse can be set to a stimulus name, in which case the subject must click on the area of the screen occupied by the stimulus.
In the following trial, pressing the space bar or "8" key is considered correct:
<trial myTrial>
/ stimulusTimes=[0=myText]
/ inputDevice=keyboard
/ correctResponse=(" ", "8")
</trial>
In the following trial, pressing the tab key is considered correct:
<trial myTrial>
/ stimulusTimes=[0=myText]
/ inputDevice=keyboard
/ correctResponse=(15)
</trial>
In the following trial, pressing the key with a scancode or character value equal to the value.leftresponse and value.rightresponse properties is considered correct:
<trial myTrial>
/stimulusTimes=[0=myText]
/ inputDevice=keyboard
/ correctResponse=(values.leftresponse, values.rightresponse)
</trial>
In the following trial, a right mouse press is considered correct:
<trial myTrial>
/ stimulusTimes=[0=myText]
/ inputDevice=mouse
/ correctResponse=(rButtonDown)
</trial>
In the following trial, moving the right joystick left or right is considered correct:
<trial myTrial>
/ stimulusTimes=[0=myText]
/ inputDevice=joystick
/ correctResponse=(rightthumbstickLeft, rightthumbstickRight)
</trial>
In the following trial, a clicking the area on the screen occupied by the "myText" stimulus is considered correct:
<trial myTrial>
/ stimulusTimes=[0=myText]
/ inputDevice=mouse
/ correctResponse=(myText)
</trial>
In the following trial, pronouncing the currently selected item in "myText" is considered correct:
<trial myTrial>
/ stimulusTimes=[0=myText]
/ inputDevice=voice
/ correctResponse=(myText)
</trial>
In the following trial, typing the currently selected item in "myText" is considered correct:
<openended myTrial>
/ stimulusTimes=[0=myText]
/ correctResponse=(myText)
</openended>
In the following trial, typing "yes" is considered correct:
<openended myTrial>
/ stimulusTimes=[0=myText]
/ correctResponse=("yes")
</openended>
In the following trial, the absence of a response before the 1000 millisecond deadline is considered correct:
<trial myTrial>
/ stimulusTimes=[0=myText]
/ inputDevice=voice
/ validResponse=(myText)
/ correctResponse=(noResponse)
/ timeout = 1000 </trial>