Image Stimulus Randomisation

Hey!

I am trying to create a pretty basic study involving showing a participant an image and then getting them to rate how dangerous they perceived it to be. This is pretty straight forwards and I have this set up and working well. However I am having an issue when I try to randomise the set of images I am using.
I have them set up in separate trial blocks ie,
(Trial with image one + rating) then (trial with image 2 + rating) and so on.

However I want to be able to present the images in a random order. The only way I am aware of doing this is through connecting my images into a spreadsheet and entering that into a loop.
My question is, how on earth do I connect images to a spreadsheet document, in order for PsychoPy to know where they are and how to access the images through said spreadsheet?

Any guidance would be massively appreciated!
Shona

Hi Shona,

You don’t “connect images to your spreadsheet”. You enter the location of the image files in the spreadsheet as simple text. In the same way, we don’t colour a cell in the spreadsheet, but use a text representation of a colour, like 'red' or ‘#FF0000’, that PsychoPy can read and use.

e.g. if you have an ‘images’ subdirectory next to your Builder file, then you would have a column that looks something like this in your conditions file:

image_name
images/cat.jpg
images/dog.jpg
images/pig.jpg

etc

Then in your image stimulus, simply put this in the “Image” field:

$image_name