Abstract
Single cell electrophysiology remains one of the most widely used approaches of systems neuroscience. Real-time feedback during electrophysiology experiments is important to guide experimental decisions that eventually determine the quality of recording, duration of the project and value of the collected data. We present an open-source tool that enables flexible online visualization of action potential alignment to external events, called the peri-event or peristimulus time histogram (OPETH). Based on the Open Ephys open source data acquisition system, we developed a Python interface for real-time plotting of neuronal spike times and evoked waveforms with respect to external events represented by digital logic signals. These digital inputs may signal photostimulation time stamps for in vivo optogenetic identification of cell types or the times of behaviorally relevant events during in vivo behavioral neurophysiology experiments. Therefore, OPETH allows real-time identification of genetically defined neuron types or behaviorally responsive populations. By allowing ‘hunting’ for neurons of interest, OPETH may significantly increase the efficiency of experiments that combine in vivo electrophysiology with behavior or optogenetic tagging of neurons.