Rotating images

Hello,
I am a very new Psychopy user and just starting to get to grips with it by watching Youtube videos. I am trying to create a visual discrimination task where participants are presented with 1 photo on one half the screen and on the other half of the screen there are 2 rotated versions of that stimulus and one that is in the same orientation. However, I am confused how to randomly rotate images on each stage and how to include multiple photos on the screen with that set up at a time.
Sorry if this is an easy thing to do I am struggling to find any tutorials on it.
Would be great if someone could explain it or show me where I can figure it out.
Thank you so much :slight_smile:

You need a conditions file with four columns.

  • In the first, put the file name for the current trial (e.g. images/cat.jpg, assuming you have a sub-folder called “images”).
  • In the next three, put the rotation values for each of the three images on the right side. Give them column names like rotation_top, rotation_middle, etc.
  • Create four image components in your routine. The left-hand one will have a constant orientation value of 0. In the other three, put rotation_top, rotation_middle, etc in each one as appropriate, and set the field to update “every repeat” rather than be constant.
  • Put a loop around your routine and connect it to your conditions file. The values will now update on every trial as required. The balancing of rotation values is handled by the structure of your conditions file.
1 Like

Thank you so much for taking time to replying and helping me!!
This is so helpful, I will try it out! Thank you so so so much!! :smiley: