An interactive tool for visualization of spike train synchronization

4
Journal of Neuroscience Methods 191 (2010) 145–148 Contents lists available at ScienceDirect Journal of Neuroscience Methods journal homepage: www.elsevier.com/locate/jneumeth Short communication An interactive tool for visualization of spike train synchronization Kevin Terry Kessler Foundation Research Center, 1199 Pleasant Valley Way, W. Orange, NJ 07052, United States article info Article history: Received 8 December 2009 Received in revised form 21 May 2010 Accepted 26 May 2010 Keywords: Spike train Coherence Synchronization Model abstract A number of studies have examined the synchronization of central and peripheral spike trains by applying signal analysis techniques in the time and frequency domains. These analyses can reveal the presence of one or more common neural inputs that produce synchronization. However, synchronization measure- ments can fluctuate significantly due to the inherent variability of neural discharges and a finite data record length. Moreover, the effect of these natural variations is further compounded by the number of parameters available for calculating coherence in the frequency domain and the number of indices used to quantify short-term synchronization (STS) in the time domain. The computational tool presented here provides the user with an interactive environment that dynamically calculates and displays spike train properties along with STS and coherence indices to show how these factors interact. It is intended for a broad range of users, from those who are new to synchronization to experienced researchers who want to develop more meaningful and effective computational and experimental studies. To ensure this freely available tool meets the needs of all users, there are two versions. The first is a stand-alone version for educational use that can run on any computer. The second version can be modified and expanded by researchers who want to explore more in-depth questions about synchronization. There- fore, the distribution and use of this tool should both improve the understanding of fundamental spike train synchronization dynamics and produce more efficient and meaningful synchronization studies. © 2010 Elsevier B.V. All rights reserved. 1. Introduction Because of what they may reveal about cognitive and motor function, the strength and nature of spike train synchronization have been studied for both central (Brody, 1998; de la Rocha et al., 2007) and peripheral processes (Santello and Fuglevand, 2004; Yao et al., 2000; Amjad et al., 1997; De Luca et al., 1993). In the time domain, synchronization typically refers to short-term synchro- nization (STS), which reveals the incidence of near-simultaneous discharges. STS is quantified by one of several indices that are based on the cross-correlation of spike train event times (Halliday et al., 2006). Alternately, synchrony can be quantified in the frequency domain by calculating spike train coherence, which is used to detect the presence of one or more neural common inputs and, if present, quantify input strength and frequency. Instead of relying on one of multiple indices that have unbounded maxima, as STS does, coher- ence is a deterministic function that produces a bounded metric that varies from 0 (incoherent) to 1 (fully coherent) (Rosenberg et al., 1989). The computation of STS and coherence from spike train event times is a straightforward process, however, due to the inherent variability of spike trains, predicting and visualizing the effects of varying spike train and common input parameters is Tel.: +1 973 324 3533; fax: +1 973 243 6984. E-mail address: [email protected]. difficult. Additionally, the availability of multiple coherence com- putation parameters and STS indices makes the interpretation of synchronization measurements even more problematic. Therefore, to provide better insight into the effects of these parameters, a LabVIEW virtual instrument (VI) has been devel- oped to produce simulated spike trains using an integrate-and-fire neuron model (Halliday, 1998) and perform dynamic STS and coherence calculations. By providing real-time interactive control over spike train model parameters, this VI produces dynamic dis- plays of simulated membrane voltages. If these voltages increase with time, threshold crossings are displayed and recorded as spike events. As model parameters are changed, the spike train discharge properties change as well, allowing for the emulation of physiologi- cal trains. More importantly, this tool displays dynamically updated cross-correlogram and coherence plots, along with live tracking of STS and coherence indices. 2. Materials and methods Spike train simulations and signal analyses are performed using LabVIEW 8.2 (National Instruments) on a PC with a Pentium ® D 3.0 GHz processor and Windows ® XP OS. 2.1. Spike train simulation Simulated spike trains are produced with a leaky integrator model that was described in detail in an earlier study (Terry and 0165-0270/$ – see front matter © 2010 Elsevier B.V. All rights reserved. doi:10.1016/j.jneumeth.2010.05.018

Transcript of An interactive tool for visualization of spike train synchronization

Page 1: An interactive tool for visualization of spike train synchronization

S

A

KK

a

ARRA

KSCSM

1

fh2edndo2dtqmetettt

0d

Journal of Neuroscience Methods 191 (2010) 145–148

Contents lists available at ScienceDirect

Journal of Neuroscience Methods

journa l homepage: www.e lsev ier .com/ locate / jneumeth

hort communication

n interactive tool for visualization of spike train synchronization

evin Terry ∗

essler Foundation Research Center, 1199 Pleasant Valley Way, W. Orange, NJ 07052, United States

r t i c l e i n f o

rticle history:eceived 8 December 2009eceived in revised form 21 May 2010ccepted 26 May 2010

eywords:pike trainoherenceynchronizationodel

a b s t r a c t

A number of studies have examined the synchronization of central and peripheral spike trains by applyingsignal analysis techniques in the time and frequency domains. These analyses can reveal the presence ofone or more common neural inputs that produce synchronization. However, synchronization measure-ments can fluctuate significantly due to the inherent variability of neural discharges and a finite datarecord length. Moreover, the effect of these natural variations is further compounded by the numberof parameters available for calculating coherence in the frequency domain and the number of indicesused to quantify short-term synchronization (STS) in the time domain. The computational tool presentedhere provides the user with an interactive environment that dynamically calculates and displays spiketrain properties along with STS and coherence indices to show how these factors interact. It is intended

for a broad range of users, from those who are new to synchronization to experienced researchers whowant to develop more meaningful and effective computational and experimental studies. To ensurethis freely available tool meets the needs of all users, there are two versions. The first is a stand-aloneversion for educational use that can run on any computer. The second version can be modified andexpanded by researchers who want to explore more in-depth questions about synchronization. There-

use oamic

fore, the distribution andtrain synchronization dyn

. Introduction

Because of what they may reveal about cognitive and motorunction, the strength and nature of spike train synchronizationave been studied for both central (Brody, 1998; de la Rocha et al.,007) and peripheral processes (Santello and Fuglevand, 2004; Yaot al., 2000; Amjad et al., 1997; De Luca et al., 1993). In the timeomain, synchronization typically refers to short-term synchro-ization (STS), which reveals the incidence of near-simultaneousischarges. STS is quantified by one of several indices that are basedn the cross-correlation of spike train event times (Halliday et al.,006). Alternately, synchrony can be quantified in the frequencyomain by calculating spike train coherence, which is used to detecthe presence of one or more neural common inputs and, if present,uantify input strength and frequency. Instead of relying on one ofultiple indices that have unbounded maxima, as STS does, coher-

nce is a deterministic function that produces a bounded metrichat varies from 0 (incoherent) to 1 (fully coherent) (Rosenberg

t al., 1989). The computation of STS and coherence from spikerain event times is a straightforward process, however, due tohe inherent variability of spike trains, predicting and visualizinghe effects of varying spike train and common input parameters is

∗ Tel.: +1 973 324 3533; fax: +1 973 243 6984.E-mail address: [email protected].

165-0270/$ – see front matter © 2010 Elsevier B.V. All rights reserved.oi:10.1016/j.jneumeth.2010.05.018

f this tool should both improve the understanding of fundamental spikes and produce more efficient and meaningful synchronization studies.

© 2010 Elsevier B.V. All rights reserved.

difficult. Additionally, the availability of multiple coherence com-putation parameters and STS indices makes the interpretation ofsynchronization measurements even more problematic.

Therefore, to provide better insight into the effects of theseparameters, a LabVIEW virtual instrument (VI) has been devel-oped to produce simulated spike trains using an integrate-and-fireneuron model (Halliday, 1998) and perform dynamic STS andcoherence calculations. By providing real-time interactive controlover spike train model parameters, this VI produces dynamic dis-plays of simulated membrane voltages. If these voltages increasewith time, threshold crossings are displayed and recorded as spikeevents. As model parameters are changed, the spike train dischargeproperties change as well, allowing for the emulation of physiologi-cal trains. More importantly, this tool displays dynamically updatedcross-correlogram and coherence plots, along with live tracking ofSTS and coherence indices.

2. Materials and methods

Spike train simulations and signal analyses are performed usingLabVIEW 8.2 (National Instruments) on a PC with a Pentium® D3.0 GHz processor and Windows® XP OS.

2.1. Spike train simulation

Simulated spike trains are produced with a leaky integratormodel that was described in detail in an earlier study (Terry and

Page 2: An interactive tool for visualization of spike train synchronization

146 K. Terry / Journal of Neuroscience Methods 191 (2010) 145–148

Table 1Default values and ranges for each computational and display parameter.

Parameter Default value Range Increment

�t (ms) 1 1–5 1� (ms) 0.025 0–0.5 0.005Samples (per segment) 512 512–4096 512Data record (s) 60 15–120 15Overlap (of segments) 50% 0–90% 1%Detrend On On/Off –Window type Hanning Rectangular, Hanning, Hamming, Blackman–Nuttall,

7-term Blackman–Harris, Triangle, and Gaussian–

� 1.1 and 1.2 0.997–2.0 0.0005� 0.2 0.0–1.0 0.05�r 0.0 −0.5 to 0.5 0.05�r 0.0 0.0–0.5 0.01Frequency (Hz) 30 10–50 1 HzCV 0.1 0.0–0.5 0.01

–0.11

Gepdvsvv

x

ToG

fai

v

y

Tmaotaedo

vrtdaaa

ittbcvs

Ap 1.5 0–5Pulse width (ms) 2 1–5Alpha (˛) 0.05 0.01Peak bins 7 3–1

riffin, 2009). That study examined the effect of spike train prop-rties, common input strength and variability, and computationalarameters on the effectiveness of coherence measurements inetecting the presence of a common input. The model sums inputoltages (with simultaneous voltage leakage) at sequential timeteps until a threshold voltage (vth) is reached. The independentoltage input (xt) is found using Eq. (1), where � is the mean inputoltage at each time step.

t = � + � ∗ nrand(t) (1)

he input voltage variability for a given time step is the productf the desired standard deviation (�) and nrand(t), selected using aaussian white noise generator (zero mean, unity variance).

Membrane voltage at each successive time step (vt+1) is thenound using Eq. (2), which uses a backward Euler integration todd common input voltage, represented as yt+1, to the independentnput voltage.

t+1 = �

�t + �vt + �t

�t + �(xt+1 + yt+1) (2a)

t+1 = Apkp (2b)

he common input is modeled as a train of rectangular pulses with aean frequency and a coefficient of variance (CVcom). Each pulse has

n amplitude Ap and a pulse width that is established by the numberf consecutive time steps during which the pulse is active. Whenhe common input is active during the t + 1 time step, kp = 1 andvoltage of Ap is added to the independent input (yt+1 = Ap). Oth-

rwise, kp = 0, removing the common input for that time step. Theefault pulse width (2 ms) is intended to approximate the durationf an action potential.

The first term on the right side of (2a) represents the membraneoltage preserved over a single time step, whereas the second termepresents the summed input voltages. As can be seen in Eq. (2),he size of the time constant (�) relative to the time step (�t) isirectly proportional to the amount of residual membrane voltagend inversely proportional to the input voltage added for each iter-tion. For this model, �t is fixed at 1 ms for a sampling rate of 1 kHznd a default � of 0.025 s.

To initiate a spike train, a random initial membrane voltage (v0)s assigned so that 0 ≤ v0 ≤ vth = 1.0. Voltage leakage and inputs arehen summed at each successive time step using Eq. (2) and, each

ime vt+1 exceeds the threshold, a spike firing time is recorded. Ifoth membrane voltages are close to threshold (vth = 1) when theommon input pulse is active, the common input can raise botholtages over the threshold at or near the same time, producing aynchronous or near-synchronous discharge. After discharge, the

0.110.012

membrane voltage is reset to vt+1–vth if the mean reset voltage bias(�r) and its standard deviation (�r) are zero. Otherwise, the resetcan be made to reset at some other mean value between −0.5 and0.5 with a standard deviation from 0.0 to 0.5. This variable resetcan also be changed to a more advanced model, such as the onedescribed by Jolivet et al. (2004).

2.2. Short-term synchronization

The STS indices are calculated using a cross-correlogram identi-cal to those used in physiological STS indices (Ellaway and Murthy,1985; Nordstrom et al., 1992), with interspike lag time bins cen-tered at 1-ms intervals from −100 to 100 ms. The default peakregion is −3.5 ms ≤ lag time ≤ +3.5 ms (seven central bins), witha range that can be varied from 3 to 11 bins. The computationalindices CIS (common input strength) and k′ − 1 are computed asshown in Eqs. (3) and (4).

CIS (s−1) = extra eventsdata record length (s)

(3)

k′ − 1 = extra eventsexpected events

(4)

where extra events are those within the peak region above themean bin count (displayed) and expected events are those withinthe peak region below the mean bin count.

2.3. Coherence analysis

Spike trains consist of binary values at 1-ms intervals that areassigned a “1” if the interval bounded a spike event time or a “0” ifnot (Rosenberg et al., 1989). Coherence is calculated using detrend-ing, segment size, tapering windows, and segment overlap specifiedon the VI front panel using built-in LabVIEW VIs. The coherence plotincludes a dynamic display of the coherence confidence level thattakes into account window type, segment size, and segment over-lap (Terry and Griffin, 2009). The two coherence indices that aretracked are the peak coherence from 0 to 50 Hz and the coherenceindex. The coherence index is the ratio of the area under the coher-ence plot (0–50 Hz) that exceeds the significance level divided bythe entire area above the significance level, producing a value from0 to 1.

2.4. Layout

The tool’s interactive front panel allows for control of the param-eters used to produce simulated spike trains, a common input,

Page 3: An interactive tool for visualization of spike train synchronization

K. Terry / Journal of Neuroscience Methods 191 (2010) 145–148 147

alizat

aalttpso9p

arsatpa

Fig. 1. Screenshot of spike train synchronization visu

nd both types of synchronization indices (Fig. 1). Default valuesnd ranges for all parameters are listed in Table 1. In the uppereft-hand corner are controls for setting the time increment (�t),ime constant (�), and data record length, which determines spikerain duration. Below these controls are those for coherence com-utation, which include a detrending (mean removal) option andettings for segment sample size, taper window type, and segmentverlap. The coherence confidence level can also be varied from0% to 99% (95% default) by changing the alpha value on the frontanel from 0.1 to 0.01, respectively.

To the right of this column are the controls for selecting the �nd � values for each spike train and the �r and �r values for voltageeset control. Although there is some interaction between � and �,

pike train firing rate generally increases with �, as standard devi-tion does with �. Firing rate, standard deviation, and CV for eachrain are all displayed adjacent to the � and � values. Common inputarameter selection is more direct, with settings for frequency, CV,mplitude (Ap), and pulse width. Displays of each train’s membrane

ion tool with annotation of major input and displays.

voltage and spikes are located to the right of their parameters, as isthe display of common input pulses.

The front panel center column contains the display of thespike train power spectra and a composite plot of the spike trainsand common input pulses, which aid with visualization of tem-poral alignment. At the far right are the dynamically updatedcross-correlation and coherence plots with corresponding STS andcoherence indices, as well as subplots that show trend diagrams foreach index. The number of peak region bins can be adjusted by acontrol on the left side of the cross-correlation plot.

2.5. Operation

Computation is started by selecting the LabVIEW ‘Run’ button inthe command toolbar (not shown) and is stopped using the ‘STOP’button on the left-hand side of the display. Because the data bufferpreserves the most current data record, it is necessary to wait aslong as the data record length for stable results after the program

Page 4: An interactive tool for visualization of spike train synchronization

1 ence M

isus

cn

3

n‘stewmise

fwdtsiaSeto

sci

dination of forces. Exp Brain Res 2004;159:501–8.Terry K, Griffin L. Coherence and short-term synchronization are insensitive to motor

48 K. Terry / Journal of Neurosci

s started or after any changes are made to record length, sampleize, or segment overlap. For initial familiarization, this tool can besed to visualize interactions that are relevant to synchronizationtudies, such as:

The combination of any segment taper and at least a 50% seg-ment overlap will increase coherence amplitude and reduce falsecoherence indications at frequencies other than that set for thecommon input.As data records are reduced in length, coherence detectionbecomes less reliable, regardless of segment taper and overlap.Increasing the CV of the common input will reduce coherenceamplitude but leave STS measurements unaffected.As common input frequency approaches one or both spike traindischarge rates, coherence will be attenuated, even though allspike train properties and other common input parameters areunchanged.

These are examples of how indicated common input strengthan vary even though although actual common input strength isot changed.

. Discussion

This tool provides visualization of spike train synchronizationot possible with individual fixed plots that only provide single

snapshots’ of coherence and STS. The dynamic displays reveal thatynchronization indices for two spike trains will vary with time andhis variability will be higher for shorter trains, even if the trainsxhibit strong stationarity (fixed mean and variance). As can be seenith this tool, the inherent variability of spike trains and the choicesade regarding common input and computational parameters are

nterrelated in such a way that variable outputs are inevitable andometimes unpredictable. In turn, this variability can have largeffects on study outcomes and conclusions.

One of the most appealing features of this tool is its potentialor complementing existing synchronization studies and assistingith the development of hypotheses for experimental protocolsesigned to examine the presence and effects of synchroniza-ion. For example, experimental design could be enhanced if theynchronization of simulated trains that emulate those recordedn earlier studies are analyzed for the computational parametersnd minimize trial durations needed for optimal coherence orTS detection. Performing this type of analysis before conductingxperiments could help prevent studies with poor coherence detec-ion due to insufficient trial duration, unnecessarily lengthy trials,

r poorly optimized signal analyses.

For those who want to use the tool in its original form, atand-alone version will also be freely available for use on anyomputer, even if LabVIEW is not installed. However, this tools intended to take advantage of the modular structure of Lab-

ethods 191 (2010) 145–148

VIEW VIs and their broad use in the neuroscience and engineeringcommunities. Therefore, a modifiable version will also be madeavailable to researchers who want to customize it according to theirneeds and interests. For those with a working knowledge of Lab-VIEW, this VI can be modified to use additional or alternate STSand coherence indices, alternate neuron models (i.e., other thanintegrate-and-fire), or additional common inputs and spike trainsthat are controlled individually or in groups. Finally, the abilityto record output files can be added so that the outcome of vari-ous scenarios can be preserved and reviewed at a later time. Bytailoring this model to meet the specific needs of researchers, syn-chronization scenarios of greater variety and complexity can beexamined without performing invasive and time-consuming phys-iological studies. Ultimately, it will provide new and experiencedresearchers with a better grasp of synchronization dynamics andidiosyncrasies that will enable them to investigate inconsistenciesof past studies and develop more effective new ones.

Appendix A. Supplementary data

Supplementary data associated with this article can be found, inthe online version, at doi:10.1016/j.jneumeth.2010.05.018.

References

Amjad AM, Halliday DM, Rosenberg JR, Conway BA. An extended difference ofcoherence test for comparing and combining several independent coherenceestimates: theory and application to the study of motor units and physiologicaltremor. J Neurosci Methods 1997;73:69–79.

Brody CD. Slow covariations in neuronal resting potentials can lead to artefactuallyfast cross-correlations in their spike trains. J Neurophysiol 1998;80:3345–51.

de la Rocha J, Doiron B, Shea-Brown E, Josic K, Reyes A. Correlation between neuralspike trains increases with firing rate. Nature 2007;448:802–6.

De Luca CJ, Roy AM, Erim Z. Synchronization of motor-unit firings in several humanmuscles. J Neurophysiol 1993;70:2010–23.

Ellaway PH, Murthy KS. The source and distribution of short-term synchronybetween gamma-motoneurones in the cat. Q J Exp Physiol 1985;70:233–47.

Halliday DM. Generation and characterization of correlated spike trains. ComputBiol Med 1998;28:143–52.

Halliday DM, Rosenberg JR, Breeze P, Conway BA. Neural spike train synchronizationindices: definitions, interpretations, and applications. IEEE Trans Biomed Eng2006;53:1056–66.

Jolivet R, Lewis TJ, Gerstner W. Generalized integrate-and-fire models of neuronalactivity approximate spike trains of a detailed model to a high degree of accu-racy. J Neurophysiol 2004;92(2):959–76.

Nordstrom MA, Fuglevand AJ, Enoka RM. Estimating the strength of common inputto human motoneurons from the cross-correlogram. J Physiol 1992;453:547–74.

Rosenberg JR, Amjad AM, Breeze P, Brillinger DR, Halliday DM. The Fourier approachto the identification of functional coupling between neuronal spike trains. ProgBiophys Mol Biol 1989;53:1–31.

Santello M, Fuglevand AJ. Role of across-muscle motor unit synchrony for the coor-

unit spike train nonstationarity. J Neurosci Methods 2009.Yao W, Fuglevand RJ, Enoka RM. Motor-unit synchronization increases EMG ampli-

tude and decreases force steadiness of simulated contractions. J Neurophysiol2000;83:441–52.