other to generate movements, emotions or cognition is a central goal of neuroscience, requiring tools to record neuronal activity. For most of the twentieth century, electrophysiology was the only method available to neuroscientists to record neural activity. Although electro physiology remains the gold standard to accurately record action potentials and sub-threshold changes in membrane potential, it suffers from important shortcomings. Electrodes must be inserted into brain tissue, which causes trauma and, potentially, triggers irritability of neurons. Furthermore, the number of neurons that can be recorded simultaneously is limited, and their identity cannot be readily identified -neurons are almost always targeted blindly, and therefore there is a bias towards very active neurons. Recent advances in silicon probe technology, which now allow for multiple probes to be inserted into the brain (each with hundreds of contact sites), have expanded the number of neurons and brain regions that can be sampled with electrophysiology, but with greater invasiveness, higher cost and the same limitations compared with single-neuron electrode recordings.Optical probing of neural activity, especially calcium imaging, has become a popular alternative to electrophysiology. Recording neural activity with fluorescence probes -primarily calcium and voltage sensors -has become mainstream in neuroscience 1,2 . In particular, calcium imaging with two-photon (2P) microscopy has become the preferred method for recording neuronal ensemble dynamics in the intact brain over the past two decades 3,4 , because it offers several advantages over in vivo electrophysiology.
Principles of calcium imagingThe ability to conduct calcium imaging experiments with rigour and reproducibility requires an in-depth knowledge of what signal is being measured and how. This requires, in turn, a basic understanding of the experimental techniques and equipment necessary to detect that signal, and of the computational pipelines to analyse and interpret the signal. In general terms, calcium imaging relies on the detection of changes in intracellular calcium concentration ([Ca 2+ ] i ) using fluorescent calcium indicators. Calcium contributes to a range of complex signals within neurons, from triggering neurotransmitter release to long-lasting synaptic plasticity in dendritic branches and spines. Importantly, the [Ca 2+ ] i regulates these processes over vastly different timescales, from a few microseconds to several hours. Thus, the time course, the amplitude or the site of its action in distinct cellular compartments are all essential determinants for the function of intraneuronal calcium signals. However, when discussing calcium imaging as a means of probing neural activity, which is the principal focus of this Primer, we are referring to Ca 2+ ions entering the cell body (the soma) through voltage-gated calcium channels when a neuron fires an action potential (FiG. 1a). Therefore, because the [Ca 2+ ] i in the soma correlates with action potential firing, so...