Sets the response option at the specified index for a multiple choice question.
none
Name | Type | Description |
---|---|---|
option | string | The option for the response. |
index | integer | The index of the option to set. |
The setOption function sets the option for a multiple choice question.
The following sets the option for the first response of a radioButtons question to cake.
<trial.example>
/ onTrialBegin = { radioButtons.example.setOption("cake", 0}; }
</trial>