24 pre-written conditions - possible?
Hey everyone,
hope my message finds you well!
I am programming a new experiment in OS at the moment and encountered a difficulty (I apologize if that's a trivial thing, but just wanted to double-check before I do it!).
Let me go on about it then: I would like to test 48 participants in my study and planning to have 24 conditions (2 people per cell). I have just 4 photos to present on the computer screen, but always in a particular order per each condition (it's counterbalanced and synchronized with what they will be doing on paper, etc.), so I don't want OS to randomize it.
How I would see it for now is that I need to create 24 loops and manually add photos on sketchpads for every loop to have pre-written earlier and randomized orders. However, since I want to have 2 participants per cell, can I just do something like this:
if var.subject_nr == 1:
var.condition = 1
elif var.subject_nr == 2:
var.condition==1
elif var.subject_nr == 3:
var.condition==2
elif var.subject_nr == 4:
var.condition==2
elif var.subject_nr == 5:
var.condition==3
elif var.subject_nr == 6:
var.condition==3
to make it work (I set if statements to activate loops depending on var.condition).
Before I attach endless sketchpads, etc. I wanted to ask whether you guys think it actually is going to make sense?
I kept doing it like that now, but I am afraid that OS may crash having 24 conditions or whatever...
Would be really grateful and appreciate any feedback on that!
Cheers,
Boris
Comments
Hi Boris,
You can do something like your example (although
condition == 1
would need to have only one equals-sign! -->condition = 1
), but you'd be kind of doing things double. If the condition variable has the exact same value as the subjects variable, you might as well use the subjects variable for whatever purpose the condition variable was.But, maybe the easiest thing would be to just make a list of the four photos in one particular order (e.g.
order = [1,2,3,4]
and present them in a single trial sequence (no loops or anything, you've only got 4 pics to show, it's not worth it!), and manually change the order in the list after each two participants. Only takes 2 seconds before you start up the experiment.Cheers,
Josh
Hi Josh,
thanks for the tip!
I settled on a similar way of presenting now and using subject number as a condition.
However, I encountered another issue...no matter which order i pre-write per participant I always get the same order of presentation (not random, but every time the same for every participant). No idea where the problem is.
At the beginning I import the orders and the stimuli:
bottles_cond1 = [line.strip() for line in open(pool["condition1.txt"])]
bottles_cond2 = [line.strip() for line in open(pool["condition2.txt"])]
(and don't randomize at any time)
Then, just to show how I am showing stimuli per participant now:
Loop -> Sequence (16 cycles) -> Inline script
inline script : var.bottles_cond1_presentation = bottles_cond1.pop()
-> Sketchpad
draw image center=1 file="[bottles_cond1_presentation]" scale=0.1 show_if=always x=0 y=-2 z_index=0
And as each participant has a different order I assume it should present the stimuli in the pre-written order, but for some reason everyone has the same order...
Any idea what's wrong here?
Thanks in advance!
Boris
Sorry, just figured out what was wrong!