09-02-2020, 08:39 AM
Calculating a reaction time (RT) in Experiment Builder is a simple process of subtracting the stimulus onset time from the response time. The basic formula is:
Reaction Time = Response Time - Onset Time
As shown in the image, a clear way to implement this is to use an UPDATE_ATTRIBUTE node to store each time in a separate variable before calculating the final RT.
⚠️ Important Warning: Do Not Use .startTime
The .startTime property records when a node was entered, not when it was executed. Due to pre-loading and screen refresh cycles, this is not the true stimulus onset time. It should NOT be used for RT calculations.
Reaction Time = Response Time - Onset Time
As shown in the image, a clear way to implement this is to use an UPDATE_ATTRIBUTE node to store each time in a separate variable before calculating the final RT.
- A variable named KEY_RESPONSE_TIME is used to store the response time from Keyboard_Input.triggeredData.time (Response Time).
- Another variable, Display_On_Time, is used to store the onset time from DISPLAY_SCREEN.time (Onset Time).
- A variable named KEY_RESPONSE_TIME is used to store the response time from Keyboard_Input.triggeredData.time (Reaction Time).
⚠️ Important Warning: Do Not Use .startTime
The .startTime property records when a node was entered, not when it was executed. Due to pre-loading and screen refresh cycles, this is not the true stimulus onset time. It should NOT be used for RT calculations.