How to write the generated stimuli into an excel spreadsheet using javascript in the online experiment?

URL of experiment: none

Description of the problem: I have to generate a unique stimuli set for each participate, which could not be satisfied through shuffling based on a single data set. So I wonder how to write the generated stimuli into an excel spreadsheet using javascript in the online experiment. The Just-in-time saved excel file will be loaded as a Conditions file. Thank you.

If you are generating a spreadsheet for use in the same experiment then you can skip the saving to file stage and just save to a nested list or list of dictionaries.

Thank you. This is an elegant solution. But if I still want to use the Builder to get the variables from a spreadsheet in order to make no changes to all of my previous code mainly constructed used the Builder, is there any solution? Thank you again.

There isn’t (yet) a way to save a custom spreadsheet on the fly in an online PsychoPy experiment.

However, all you need to do to minimise changes is to have a code component at the start of your loop that reads the values from the list into the variable names you used offline.

I got it! Thank you again for your patient reply.