shuffle horiz taking values from other rows
Hi,
this is a weird problem I'm trying to figure out. I have a loop with values that will fill a multiple choice questionnaire on each cycle. I added a line to the script of the loop to shuffle the 4 possible answer options
shuffle horiz ans1 ans2 ans3 ans4
But when I run the experiment it seems to pull values from other cycles in the loop - it won't match the question with the correct answer options from the row in the loop table . I'm testing it in a browser as I intend to upload to JATOS later. I have some small javascript to check the correct answer from the mcq and calculate the overall time elapsed for the loop (as a break condition).
If I remove the "shuffle horiz" code the loop executes correctly with the appropriate answer options. It's not a critical problem for my experiment, I can get by without shuffling the 4 answer variables but I'm just trying to figure out what's going wrong.
Comments
Hi @MikeN ,
Just had a look at your task and then did some search on the shuffle horiz command and found this: https://osdoc.cogsci.nl/3.3/tutorials/visual-world/
Looks like you have to use "
shuffle_horiz" instead of "shuffle horiz". When I tried that in your task, it ran just fine. My guess is that with shuffle horiz ans1 ans2 ans3 ans4", the task looks for a variable called "horiz" and that this may somehow mess up the values coming up. In any case, I believe that "shuffle_horiz" will solve your problem.Best,
Fabrice.
Thanks @Fab!
like so many problems the answer seems obvious once I read it. I misread the shuffle_horiz command and thought that 'horiz' was a parameter. When Open Sesame didn't throw up an error I assumed I had typed it correctly but I can see now it was shuffling the variables both horizontally and vertically including the non-existent "horiz" variable.
thanks again,
Mike