Measure response time between mouse presses

Hi, I am not very good at coding. I would like help with creating a code to measure the response time between mouse clicks. My participants will be clicking on number positions in serial order and I want to see how fast they are making these judgements by measuring the time. So, if a participant presses on 1, I want to see how long before they press on 2, then 3 and so on until they complete the sequence. Ultimately, I want to measure their processing speed in this task. The task repeats until they lost all their lives so I would like the timer to reset for each trial or if possible between each mouse click.

My sequence is from 1 to 9 when all numbers are shown simultaneously and in another variation, it shows numbers sequentially one after the other and keeps adding numbers (up to 9) whenever the answer is correct. Hope this helps.

thanks for the help!

sample data output.csv (695 Bytes)
mouse_times.psyexp (15.2 KB)

Hi, I’ve made a minimal demo where 3 squares appear sequentially and named them a, b, and c. If you set the mouse save state as on valid click, whatever you defined as clickable, it’s name and reaction time will be saved in sequence within a list (see columns K and L in the sample output). Hope this helps getting you started :slight_smile: