Group: Administrators
Posts: 13K,
Visits: 108K
|
The initial response is recorded in values.initialresponse. Its correctness is stored in values.correct. Both happens in the respective <trial> elements. E.g.
<trial AAT_1> ... / iscorrectresponse = [(values.expcondition == 1 && trial.AAT_1.response == "forward") || (values.expcondition == 2 && trial.AAT_1.response == "back")] ... / ontrialend = [values.correct = trial.AAT_1.correct] ... / ontrialend = [if (trial.AAT_1.response == "forward") values.initialresponse = "PUSH" else values.initialresponse = "PULL"] </trial>
The final response is recorded in values.finalresponse. That happens in the "increase" and "decrease" <trial> elements:
<trial increase> ... /branch = [if (joystick.y >= 1000) {values.joystick_y = joystick.y; values.endtime = script.elapsedtime; values.finalresponse = "PULL"; trial.endincrease}] ... </trial>
<trial decrease> ... /branch = [if (joystick.y <= -1000) {values.joystick_y = joystick.y; values.endtime = script.elapsedtime; values.finalresponse = "PUSH"; trial.enddecrease}] ,,, </trial>
<trial endincrease> or respectively <trial endincrease> is then run as the final trial in that sequence. You would put your evaluation of the final response as well as the display of the error message in those two <trial> elements -- <trial endincrease> and <trial enddecrease>. The logic would be largely identical to the logic outlined above dealing with the initial response.
|