Hi Hillary,
Really cool to see that you are using a touch screen with PsychoPy.
I didn't realise you were already using some custom code. This should make it quite easy.
You could do something like this:
if t >= 3.5 and m1.mouseMoved():
if ImageL1.contains(m1) or ImageR1.contains(m1):
# record the current time:
thisExp.addData("mouse.RT", t)
# if you need the x, y coordinates, access them directly:
thisExp.addData("mouse.x", m1.getPos()[0]
thisExp.addData("mouse.y", m1.getPos()[1]
# end the trial:
continueRoutine = False
t is the time since the trial started, so not sure if that is what you want your latency measured relative to, but you can subtract some other time from it as required.
e.g. thisExp.addData("mouse.RT", t - 3.5) # or some other relevant value
Because you are accessing and saving the mouse data yourself, I guess you could select "never" in the "save mouse state" setting of the mouse component?
Does that help?
Mike
--
Michael R. MacAskill, PhD 66 Stewart St
Research Director, Christchurch 8011
New Zealand Brain Research Institute NEW ZEALAND
Research Fellow,
michael....@nzbri.org
Te Whare Wānanga o Otāgo, Otautahi Ph:
+64 3 3786 072
University of Otago, Christchurch
http://www.nzbri.org/macaskill