Randomly Select 1 Image Out of 6 Possible Images

OS: Win10
PsychoPy version: v2020.1.1
Standard Standalone?: Y
What are you trying to achieve?: VERY new to PsychoPy.

I have six image files, but I want to only present one of them. However, I’d like the image to be chosen randomly so that not all participants see the same image.

What did you try to make it work?: I have made an excel file that lists each image files and then created a loop using that xlsx file to select the images.

What specifically went wrong when you tried that?: It showed all six images in a random order, but I only want it to show just one out of the six images.

Put trials.finished=True in a code component to end the loop early.

trials being the name of the loop

Perfect! Thank you.