Problem with csv log

I’m ready to start my thesis project after many many tests.

This is the experiment:
A stimulus image appears for 4 sec after that two other images appear and the subject have to choose ones with a ps3 controller to go on.
The two images are one the left and one on the right and how they swing from left to right is decided by this script:

from random import shuffle
pos = [[0.4, 0], [-0.4, 0]]

My problem is that the csv file doesn’t report the final position every trial.
So i don’t know which image is choosed by the subject. How can I solved my problem?

Hi @robbu, are you using the Joystick component, and does the component dialog box look like this:

Untitled

no, only “name” and I see only 0 and 1 .

Cattura

Probably i’ve just set the joystick component so bad that it doesn’t give me the output that I want.
I’ve asked subjects to press L1 for left images and R1 for right images and yes, it stores it! for every trial when L1 is pressed and so R1. But what I need is knowing which images is displayed in that trial on the left and on the right.
I hope to be clear.

Thanks, it sounds like you just want to save the position of the images that are presented. You can do this in the End Routine tab of the code component:

thisExp.addData("leftImagePos", leftImage.pos ) 
thisExp.addData("rightImagePos", rightImage.pos ) 

# Where leftImage and rightImage are the names of your image components

ohh perfect! Now I see all the coordinates. Thank you so much!

Can I see this data in function of position?
something like 2 column of “left” and “right” and than all the images listed

but this is a big progress for my work!

If you want to save the name of the images? Then, try:

thisExp.addData("leftImage_image", leftImage.image) 
thisExp.addData("rightImage_image", rightImage.image)