diff --git a/.changeset/red-news-pull.md b/.changeset/red-news-pull.md new file mode 100644 index 0000000000..328a90185e --- /dev/null +++ b/.changeset/red-news-pull.md @@ -0,0 +1,5 @@ +--- +"@jspsych/plugin-audio-button-response": patch +--- + +annotate missing stimulus data field diff --git a/docs/plugins/audio-button-response.md b/docs/plugins/audio-button-response.md index 2f59f1a91f..6131a901f9 100644 --- a/docs/plugins/audio-button-response.md +++ b/docs/plugins/audio-button-response.md @@ -37,6 +37,7 @@ In addition to the [default data collected by all plugins](../overview/plugins.m | -------------- | ------- | ---------------------------------------- | | rt | numeric | The response time in milliseconds for the participant to make a response. The time is measured from when the stimulus first began playing until the participant's response. | | response | numeric | Indicates which button the participant pressed. The first button in the `choices` array is 0, the second is 1, and so on. | +| stimulus | string | Path to the audio file that played during the trial. | ## Simulation Mode diff --git a/packages/plugin-audio-button-response/src/index.ts b/packages/plugin-audio-button-response/src/index.ts index 96ad72ecf7..c510f91587 100644 --- a/packages/plugin-audio-button-response/src/index.ts +++ b/packages/plugin-audio-button-response/src/index.ts @@ -100,6 +100,10 @@ const info = { }, }, data: { + /** The path of the audio file that was played. */ + stimulus: { + type: ParameterType.STRING, + }, /** The response time in milliseconds for the participant to make a response. The time is measured from * when the stimulus first began playing until the participant's response.*/ rt: {