psychopy.org | Reference | Downloads | Github

How can I make psychopy to choose one from each 5 rows at random?

I have 10 rhythms and there are 5 versions of each of these rhythms in therms of their speed. I wanna create all 50 rhythms and put them into an excel file but the problem is that I want just one of 5 speeds of each rhythms be selected at random. meaning that at the end 10 rhythms will be played for the participands but at random speeds.
If I put all 5 speeds of each rhythm in the excel file in 5 rows and then the next 5 rows for 5 versions of next rhythm and so on, how can I make psychopy to choose one from each 5 rows at random?
Thanks a lot for your help.

Hi Zhaleh,

You can find the code to do this randomization and selection at this post: