Skip to content
Discussion options

You must be logged in to vote

Hi @psychNerdJae,

Because you are combining the timeline variable with other information you'll need to use a dynamic parameter.

prompt: () => { return "How much do you like " + jsPsych.timelineVariable("test_prompt") + "?"; },

When you call jsPsych.timelineVariable() it actually returns a special kind of object, which jsPsych then treats like a dynamic parameter later on during the experiment run. So you are seeing [object Object] because the value of jsPsych.timelineVariable() is this object. When you wrap the whole prompt parameter in a function, then the jsPsych engine will wait to evaluate this timelineVariable until runtime and it will return the value of the timeline variable at th…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@psychNerdJae
Comment options

Answer selected by psychNerdJae
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