ABSTRACT

Programming is an important part of experimental psychology and cognitive neuroscience, and Python is an ideal language for novices. It sports a very readable syntax, intuitive variable management, and a very large body of functionality that ranges from simple arithmetic to complex computing.

Python for Experimental Psychologists provides researchers without prior programming experience with the knowledge they need to independently script experiments and analyses in Python. The skills it offers include: how to display stimuli on a computer screen; how to get input from peripherals (e.g. keyboard, mouse) and specialised equipment (e.g. eye trackers); how to log data; and how to control timing. In addition, it shows readers the basic principles of data analysis applied to behavioural data, and the more advanced techniques required to analyse trace data (e.g. pupil size) and gaze data.

Written informally and accessibly, the book deliberately focuses on the parts of Python that are relevant to experimental psychologists and cognitive neuroscientists. It is also supported by a companion website where you will find colour versions of the figures, along with example stimuli, datasets and scripts, and a portable Windows installation of Python.

chapter 1|6 pages

Python

chapter 2|24 pages

Variable types 7

chapter 3|21 pages

Creating and presenting stimuli

chapter 4|29 pages

Processing responses

chapter 5|36 pages

Scripting an experiment 82

chapter 6|21 pages

Analysing behavioural data

chapter 7|12 pages

Analysing traces

chapter 8|22 pages

Eye tracking

chapter 9|2 pages

Getting help