Welcome! Log In Create A New Profile


Pupil size data

Posted by haozhou.jiang 
Pupil size data
April 15, 2024 09:38AM
Hi Jaewon,

I have trouble of getting the pupil size (either pupil diameter or area) during the task. I only manage to get the eye position data (x and y) using either eye_postion() or get_analog_data(). For the pupil size, I am sure Eyelink is saving it and I set the Eyelink to send the pupil data in diameter. Is there any function I can use to get 3- column data with x, y and the pupil size? Thanks!

Re: Pupil size data
April 15, 2024 11:06AM
You also need to set NIMH ML to receive the pupil data either through a voltage channel or TCP/IP.

If you receive eye XY signals through voltage channels (i.e., NI board), assign the pupil size input to one of "General Input" on the Input/Output panel of the main menu. Then you can read it like get_analog_data('gen1') in the timing script.

If you receive eye XY signals through TCP/IP, select "Pupil Size" in the "Extra" input menu of the TCP/IP eye tracker setting and read it like get_analog_data('eyeextra').

See also the manual page of get_analog_data().


By the way, change the gain of "Pupil Size" to 1 (and the offset to 0), when you select it in the TCP/IP menu. The XY signals use small gains because their output should be within -10 to 10, but, for pupil size, you want to get it exactly as sent by the eye tracker.
open | download - voltage.png (24.9 KB)
open | download - TCPIP.png (29.3 KB)

The National Institute of Mental Health (NIMH) is part of the National Institutes of Health (NIH), a component of the U.S. Department of Health and Human Services.