Post by val on Dec 13, 2021 6:45:10 GMT
Hi everyone,
I have a question about setting restrictions on how to randomise trials within a block (e.g., don't display words of the same colour and of the same category across more than 2 consecutive trials). My questions are at the very end of this post, but here's some context first...
WHAT
EXAMPLE OF CODE SO FAR
1) A table for EACH word, e.g.:
##Column 1 = name of trial; Column 2 = category of word (1 = neutral, 2 = negative); Column 3 = name of bitmap to display; Column 4 = correct redkey per word ( r(ed) = 1, g(reen) = 2, b(lue) = 3, y(ellow) = 4).
table neutral_tissue
"red neutral - Tissue" 1 Tissue_R 1
"green neutral - Tissue" 1 Tissue_G 2
"blue neutral - Tissue" 1 Tissue_B 3
"yellow neutral - Tissue" 1 Tissue_Y 4
table neutral_poker
"red neutral - Poker" 1 Poker_R 1
"green neutral - Poker" 1 Poker_G 2
"blue neutral - Poker" 1 Poker_B 3
"yellow neutral - Poker" 1 Poker_Y 4
....
2) A task for each word, e.g.:
task neutral_tissue
table neutral_tissue
part trial_actual
task neutral_poker
table neutral_poker
part trial_actual
part trial_actual
keys r g b y
delay 500
show bitmap fixpoint # stimulus 1
delay 200
clear 1 # remove fixpoint
delay 100
show bitmap @3 # stimulus 2
readkey @4 2000
clear 2 # remove stimulus 2
delay 500
save BLOCKNUMBER BLOCKNAME TRIALCOUNT @1 @2 @3 TABLEROW @4 KEY STATUS RT
3) A block (with full list of tasks -- 20 total; 1 trial per task):
block stroop_actual
set &trialcount 0
tasklist
neutral_tissue 1
neutral_poker 1
neutral_stove 1
neutral_window 1
neutral_voyage 1
neutral_wheel 1
neutral_adult 1
neutral_ballet 1
neutral_puddle 1
neutral_rower 1
negative_ordeal 1
negative_mourn 1
negative_stress 1
negative_impair 1
negative_waste 1
negative_stupid 1
negative_shame 1
negative_hinder 1
negative_scared 1
negative_fail 1
end
This runs well, with the order and colour of words randomised across the block.
QUESTION
However, I want to add the following restrictions:
I've tried different ways to do this (including revising how I've set up tables, etc). all to no avail and it is doing my head in.
Does anyone have any advice? It would be much appreciated!
Thanks in advance.
I have a question about setting restrictions on how to randomise trials within a block (e.g., don't display words of the same colour and of the same category across more than 2 consecutive trials). My questions are at the very end of this post, but here's some context first...
WHAT
- I'm coding an "emotional stroop" experiment -- where participants will see negative or neutral words in different colours, and will have to press a key ASAP corresponding to the colour of the word
- I'm using a table to set my conditions
- I have 20 words, each which could come in 1 of 4 colours (red, green, yellow, blue) on any given trial.
- Each block will consist of 20 trials, with each word showing up ONCE only
- The order and colour of the word will be randomised.
EXAMPLE OF CODE SO FAR
1) A table for EACH word, e.g.:
##Column 1 = name of trial; Column 2 = category of word (1 = neutral, 2 = negative); Column 3 = name of bitmap to display; Column 4 = correct redkey per word ( r(ed) = 1, g(reen) = 2, b(lue) = 3, y(ellow) = 4).
table neutral_tissue
"red neutral - Tissue" 1 Tissue_R 1
"green neutral - Tissue" 1 Tissue_G 2
"blue neutral - Tissue" 1 Tissue_B 3
"yellow neutral - Tissue" 1 Tissue_Y 4
table neutral_poker
"red neutral - Poker" 1 Poker_R 1
"green neutral - Poker" 1 Poker_G 2
"blue neutral - Poker" 1 Poker_B 3
"yellow neutral - Poker" 1 Poker_Y 4
....
2) A task for each word, e.g.:
task neutral_tissue
table neutral_tissue
part trial_actual
task neutral_poker
table neutral_poker
part trial_actual
part trial_actual
keys r g b y
delay 500
show bitmap fixpoint # stimulus 1
delay 200
clear 1 # remove fixpoint
delay 100
show bitmap @3 # stimulus 2
readkey @4 2000
clear 2 # remove stimulus 2
delay 500
save BLOCKNUMBER BLOCKNAME TRIALCOUNT @1 @2 @3 TABLEROW @4 KEY STATUS RT
3) A block (with full list of tasks -- 20 total; 1 trial per task):
block stroop_actual
set &trialcount 0
tasklist
neutral_tissue 1
neutral_poker 1
neutral_stove 1
neutral_window 1
neutral_voyage 1
neutral_wheel 1
neutral_adult 1
neutral_ballet 1
neutral_puddle 1
neutral_rower 1
negative_ordeal 1
negative_mourn 1
negative_stress 1
negative_impair 1
negative_waste 1
negative_stupid 1
negative_shame 1
negative_hinder 1
negative_scared 1
negative_fail 1
end
This runs well, with the order and colour of words randomised across the block.
QUESTION
However, I want to add the following restrictions:
- Don't display words of the same colour for more than 2 consecutive trials
- Don't display words of the same category for more than 2 consecutive trials
I've tried different ways to do this (including revising how I've set up tables, etc). all to no avail and it is doing my head in.
Does anyone have any advice? It would be much appreciated!
Thanks in advance.