So far, the code I have is:
Qualtrics.SurveyEngine.addOnReady(function()
{
var starttime = new Date().getTime();
$('NextButton').hide();
this.questionclick = function(event,element){
if (element.type == 'radio') {
var endtime = new Date().getTime();
var RT = endtime - starttime;
var EmData = Qualtrics.SurveyEngine.getEmbeddedData('reactiontime');
let Holder = [];
Holder.push(EmData);
Holder.push(RT);
Qualtrics.SurveyEngine.setEmbeddedData('reactiontime', Holder);
$('NextButton').click();
}
}
});
This code results in something like the following:
[[{"1":4697},2943],"10392"]
where the larger numbers are the RTs. No idea where the "1" comes from. So, it works, but is a mess. I was wondering if there was a way to alter my code so that the Embedded Data ends up looking like this by the end of the survey:
[RT1, RT2, RT3...]
rather than the messy current form.
Thanks in advance for your help!
(sorry if the formatting is poor, I am new to this forum)
Best answer by TomG
View original