| Reference | Downloads | Github

Randomize presentation of blocks

OS: Win10
PsychoPy version:1.90

Hi All!

I am trying to randomize the presentation of 2 blocks in a decision-making task. Each block contains 30 trials and I have already randomized the trial presentation in each block. However, I am confused on how to randomize the presentation of blocks itself so that on some runs the block initialized as the first block on the routine appears first and the block initialized as second on the routine appears second, but for some other runs the presentation is reversed so now the block which was initialized first in the routine appears second. I have a break segment in between these 2 blocks as a separate routine so when I do the block randomization, I must make sure in all runs the break segment/routine appears in between the 2 blocks, not before or at the end of the 2 blocks.

Any kind of help is very much appreciated!

Thanks in advance,


Hello Mo. This question has been asked multiple times on this forum. Try searching for similar topics, and in particular consult this guide:

1 Like

Thank you Michael! I solved the issue.