Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to store a javascript object into lab.js's data #232

Open
Max-Lovell opened this issue Mar 15, 2024 · 1 comment
Open

How to store a javascript object into lab.js's data #232

Max-Lovell opened this issue Mar 15, 2024 · 1 comment

Comments

@Max-Lovell
Copy link

Max-Lovell commented Mar 15, 2024

Sorry if this is the wrong locatino to post this but the slack isn't working and I can't find anywhere else to get help. I am running a lab.js experiment, and one of my tasks is written in pure html and js. I have got this to run inside lab.js but can't figure out how to get the resulting javascritp object of the participants data to save in lab.js with everything else.

What would you like or expect to see?

Store a JS object in the output data.

What is currently happening?

cannot figure out how to do this.

Please describe the steps needed to reproduce this phenomenon

N/A

Finally, please tell us which browser you're using (and the version thereof)

Chrome Version 122.0.6261.129 (Official Build) (64-bit)

@Max-Lovell
Copy link
Author

I have found if I call const ds = this.options.datastore at the start of my script and then ds.set(data) at the end I can get each trial as a separate column in my dataset. Is there a better option than this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant