PennController for IBEX › Forums › Support › Pick combined with randomizeNoMoreThan › Reply To: Pick combined with randomizeNoMoreThan
![](https://www.pcibex.net/wp-content/uploads/2018/10/IMG_8365-e1540835663655-150x150.jpg)
Hi Aliona,
The Sequence
command and the related functions only care about the trials’ labels: if you yes-answer and no-answer trials share the same labels, you won’t be able to control their distribution. I suggest you include the yes/no bit of information in the trials’ labels, eg "critical-yes"
/"critical-no"
and "filler-yes"
/"filler-no"
The pick
function will pick the N next trials from a set: when you do pick(critical,8)
and critical
was set to randomize("critical")
, it will pick 8 trials from a randomized set of all the trials labeled “critical”. Then you pass that to rshuffle
, so those 8 trials will be interspersed with trials labeled “filler” in the order in which they were picked from critical
You could do that, in which case two critical-yes trials would always be separated by a critical-no, a filler-yes and a filler-no trial:
criticalyes = randomize("critical-yes") criticalno = randomize("critical-no") fillersyes = randomize("filler-yes") fillersno = randomize("filler-no") Sequence("demographics","etc", rshuffle(pick(criticalyes,4),pick(fillersyes,6),pick(criticalno,4),pick(fillersno,5)),"break", rshuffle(pick(criticalyes,4),pick(fillersyes,5),pick(criticalno,4),pick(fillersno,6)),"break", rshuffle(pick(criticalyes,4),pick(fillersyes,6),pick(criticalno,4),pick(fillersno,5)), "etc")
Don’t forget to add -yes
/-no
to your trials’ labels, and make sure the 5
/6
match the number of different types of trials you have (I went with 17 filler-yes trials and 16 filler-no trials, for a total of 33 filler trials)
Jeremy