How to clean an array of coordinates

Hello everyone!

I apologize for the question, I’ve been sitting here for a while and this is stumping me for some reason.

In my code, I record coordinates from mouse clicks within a given trial. I am trying to compare those clicked coordinates with the coordinates of actual objects flashed during the trial. I feel this question probably won’t require my actual code, but please feel free to ask if that would help. Below is a screenshot of my output when I compare the mouse coordinates to the object coordinates (labeled ‘pos’)


Would anyone know how to make those both look the same (i.e., get rid of the ‘array’, periods after the values, and extra brackets for the mouse click coordinates)?

Thanks for your help!

How about pushing the coordinates to a new list?

mouse_clicks.append(mouse.getPos())

or

mouse_clicks.append((mouse.getPos()[0], mouse.getPos()[1]))

If this doesn’t look like the answer, please could you show the code where you are currently adding the mouse locations to mouse_clicks?

Ah! Thank you so much!

Your second solution worked perfectly. I have just been working all day and totally spaced.

I really appreciate your help!