Simultaneous measurement of program comprehension with fMRI and eye tracking: a case study

Background Researchers have recently started to validate decades-old program-comprehension models using functional magnetic resonance imaging (fMRI). While fMRI helps us to understand neural correlates of cognitive processes during program comprehension, its comparatively low temporal resolution (i.e., seconds) cannot capture fast cognitive subprocesses (i.e., milliseconds). Aims To increase the explanatory power of fMRI measurement of programmers, we are exploring in this methodological paper the feasibility of adding simultaneous eye tracking to fMRI measurement. By developing a method to observe programmers with two complementary measures, we aim at obtaining a more comprehensive understanding of program comprehension. Method We conducted a controlled fMRI experiment of 22 student participants with simultaneous eye tracking. Results We have been able to successfully capture fMRI and eye-tracking data, although with limitations regarding partial data loss and spatial imprecision. The biggest issue that we experienced is the partial loss of data: for only 10 participants, we could collect a complete set of high-precision eye-tracking data. Since some participants of fMRI studies show excessive head motion, the proportion of full and high-quality data on fMRI and eye tracking is rather low. Still, the remaining data allowed us to confirm our prior hypothesis of semantic recall during program comprehension, which was not possible with fMRI alone. Conclusions Simultaneous measurement of program comprehension with fMRI and eye tracking is promising, but with limitations. By adding simultaneous eye tracking to our fMRI study framework, we can conduct more fine-grained fMRI analyses, which in turn helps us to understand programmer behavior better.

[1]  Andrew Begel,et al.  Using psycho-physiological measures to assess task difficulty in software development , 2014, ICSE.

[2]  Andrew T. Duchowski,et al.  Eye Tracking Methodology - Theory and Practice, Third Edition , 2003 .

[3]  Yul-Wan Sung,et al.  Functional magnetic resonance imaging , 2004, Scholarpedia.

[4]  Tim Halverson,et al.  Cleaning up systematic error in eye-tracking data by using required fixation locations , 2002, Behavior research methods, instruments, & computers : a journal of the Psychonomic Society, Inc.

[5]  Alan Kennedy,et al.  Book Review: Eye Tracking: A Comprehensive Guide to Methods and Measures , 2016, Quarterly journal of experimental psychology.

[6]  Sven Apel,et al.  Views on Internal and External Validity in Empirical Software Engineering , 2015, 2015 IEEE/ACM 37th IEEE International Conference on Software Engineering.

[7]  Henrique Madeira,et al.  WAP: Understanding the Brain at Software Debugging , 2016, 2016 IEEE 27th International Symposium on Software Reliability Engineering (ISSRE).

[8]  Andrew L Cohen Software for the automatic correction of recorded eye fixation locations in reading experiments , 2013, Behavior research methods.

[9]  Sven Apel,et al.  Measuring neural efficiency of program comprehension , 2017, ESEC/SIGSOFT FSE.

[10]  Jonathan I. Maletic,et al.  An Eye Tracking Study on camelCase and under_score Identifier Styles , 2010, 2010 IEEE 18th International Conference on Program Comprehension.

[11]  B. Chance,et al.  Cognition-activated low-frequency modulation of light absorption in human brain. , 1993, Proceedings of the National Academy of Sciences of the United States of America.

[12]  Scott P. Robertson,et al.  Expert problem solving strategies for program comprehension , 1991, CHI.

[13]  N. Pennington Stimulus structures and mental representations in expert comprehension of computer programs , 1987, Cognitive Psychology.

[14]  Sven Apel,et al.  Measuring and modeling programming experience , 2013, Empirical Software Engineering.

[15]  Susan Wiedenbeck,et al.  Navigation and comprehension of programs by novice programmers , 2001, Proceedings 9th International Workshop on Program Comprehension. IWPC 2001.

[16]  Kathrin Pollmann,et al.  fNIRS as a Method to Capture the Emotional User Experience: A Feasibility Study , 2016, HCI.

[17]  Markku Tukiainen,et al.  An eye-tracking methodology for characterizing program comprehension processes , 2006, ETRA.

[18]  Ben Shneiderman,et al.  Syntactic/semantic interactions in programmer behavior: A model and experimental results , 1979, International Journal of Computer & Information Sciences.

[19]  Thomas Leich,et al.  Toward measuring program comprehension with functional magnetic resonance imaging , 2012, SIGSOFT FSE.

[20]  Christopher Exton Constructivism and program comprehension strategies , 2002, Proceedings 10th International Workshop on Program Comprehension.

[21]  Henrique Madeira,et al.  The role of the insula in intuitive expert bug detection in computer code: an fMRI study , 2018, Brain Imaging and Behavior.

[22]  Danial Hooshyar,et al.  Mining biometric data to predict programmer expertise and task difficulty , 2017, Cluster Computing.

[23]  C. Koch,et al.  Task-demands can immediately reverse the effects of sensory-driven saliency in complex visual stimuli. , 2008, Journal of vision.

[24]  L. Garey Brodmann's localisation in the cerebral cortex , 1999 .

[25]  Andrew Begel,et al.  Eye Movements in Code Reading: Relaxing the Linear Order , 2015, 2015 IEEE 23rd International Conference on Program Comprehension.

[26]  Thomas D. LaToza,et al.  Maintaining mental models: a study of developer work habits , 2006, ICSE.

[27]  Sven Apel,et al.  Toward conjoint analysis of simultaneous eye-tracking and fMRI data for program-comprehension studies , 2018, EMIP@ETRA.

[28]  André Brechmann,et al.  Determining language laterality by fMRI and dichotic listening , 2007, Brain Research.

[29]  Bonita Sharif,et al.  Towards automating fixation correction for source code , 2016, ETRA.

[30]  Susan Wiedenbeck,et al.  The Initial Stage of Program Comprehension , 1991, Int. J. Man Mach. Stud..

[31]  Venera Arnaoudova,et al.  The Effect of Poor Source Code Lexicon and Readability on Developers' Cognitive Load , 2018, 2018 IEEE/ACM 26th International Conference on Program Comprehension (ICPC).

[32]  Kate Ehrlich,et al.  Empirical Studies of Programming Knowledge , 1984, IEEE Transactions on Software Engineering.

[33]  Arthur M. Jacobs,et al.  OGAMA (Open Gaze and Mouse Analyzer): Open-source software designed to analyze eye and mouse movements in slideshow study designs , 2008, Behavior research methods.

[34]  Ruven E. Brooks,et al.  Towards a Theory of the Comprehension of Computer Programs , 1983, Int. J. Man Mach. Stud..

[35]  Thomas Leich,et al.  Understanding understanding source code with functional magnetic resonance imaging , 2014, ICSE.

[36]  Thomas A. Standish An Essay on Software Reuse , 1984, IEEE Transactions on Software Engineering.

[37]  P. Tibbetts :Cognitive Neuroscience: The Biology of the Mind , 2009 .

[38]  Westley Weimer,et al.  Decoding the Representation of Code in the Brain: An fMRI Study of Code Review and Expertise , 2017, 2017 IEEE/ACM 39th International Conference on Software Engineering (ICSE).

[39]  Andrew T. Duchowski,et al.  Eye Tracking Methodology: Theory and Practice , 2003, Springer London.