Skip to content
Discussion options

You must be logged in to vote

I think this is happening because each of your timeline.concat lines is merging the empty timeline array with con_screen1, con_screen2 etc. (not sure if these are arrays or objects?) and assigning the result to the same variable (e.g. timeline_condition_control). So the concat lines aren't combining all of these things into one array - instead each line is combining an empty array with something else, and then overwriting the same variable with that result.

If you're trying to add objects (trials or trial procedures) onto the end of these different timeline arrays, then you can try creating an empty array and using .push to add trials onto the end of it:

var timeline_condition_control = [];

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@ggc1998
Comment options

@becky-gilbert
Comment options

Answer selected by becky-gilbert
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants