Building in experiment with different combinations of stimuli for each subject #1705
-
Is there a way for the user to tell the program in Cognition.run which condition you are running. For example, if I want to assign different orders of stimuli to different people, can I do that? Or, would that necessitate building multiple versions of the experiment, each with a different link? Here is source code, though it is subject to change:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Yes, you can do this in a single experiment in cognition.run. If you click on your expeirment settings in cognition.run, then go to Design -> Configuration -> Advanced -> Inter experiment conditions, then enter the number of conditions that you want counterbalanced. Then when you run your experiment, you'll automatically have access to the condition number assigned to the participant with a variable // create a variable called stimuli and give it different values based on the condition number
var stimuli;
if (CONDITION == 1) {
stimuli = stimuli_version_1;
} else if (CONDITION == 2) {
stimuli = stimuli_version_2;
} else {
stimuli = stimuli_version_3;
}
// then set up the experiment using the stimuli array I hope that helps. Let us know if you need any further guidance. |
Beta Was this translation helpful? Give feedback.
Yes, you can do this in a single experiment in cognition.run. If you click on your expeirment settings in cognition.run, then go to Design -> Configuration -> Advanced -> Inter experiment conditions, then enter the number of conditions that you want counterbalanced. Then when you run your experiment, you'll automatically have access to the condition number assigned to the participant with a variable
CONDITION
(this is explained in the text below the "Inter experiment conditions" box). Then, in your code, you can use theCONDITION
variable to change the way your experiment is set up, e.g.