Converting and analysing data

The ASA program saves four files for each data capture session. These are:

  • FILENAME.cnt – the main data file
  • FILENAME.trg – details of triggers
  • FILENAME.evt – details of event markers
  • FILENAME.sen – details of separate recording blocks within a session

ASA itself can be used for some simple analyses of EEG data. All of the processing and analysis steps are included in the graphical user interface (GUI), making it easy to use for demonstrations and for people with little scripting experience.  However, we recommend that you export your data into a different programme (e.g. MATLAB) for analysis, since ASA is not suitable for more sophisticated analyses and it can only be accessed via a PC with a USB license dongle. Many of these more sophisticated analysis tools also have well-developed GUIs, Wikis, Tutorials and support forums.

The sections below mainly focus on software that is freely-available (either standalone or as toolboxes for MATLAB). This list gives some examples that have been used previously by members of the Department and is not comprehensive in covering all of the available software. Commonly paid-for software that are not listed here include: NeuroScan, BESA, and BrainVision, amongst others.

Note that using the MATLAB toolboxes for analyses can be quite memory-intensive. We have found in the past that a 64-bit version of Windows or Linux and MATLAB (available from the Department) is necessary for analysing large EEG datasets with 64 electrodes (beyond preprocessing). A computer with lots of RAM is also desirable!

 

EEGLAB (A toolbox for MATLAB)

The EEG toolbox can be downloaded here: http://sccn.ucsd.edu/eeglab/. The website provides links to the EEGLAB Wiki and Tutorials. For more information, join search the EEGLAB mailing list (http://sccn.ucsd.edu/eeglab/eeglabmail.html). A script to convert .cnt files to Matlab format automatically is available here.

Useful references

Delorme, A., & Makeig, S. (2004). EEGLAB: an open source toolbox for analysis of single-trial EEG dynamics including independent component analysis. Journal of neuroscience methods, 134(1), 9–21.

Additional references can be found here: http://sccn.ucsd.edu/eeglab/refs.html 

 

FieldTrip (A toolbox for MATLAB)

The FieldTrip toolbox can be downloaded here: http://fieldtrip.fcdonders.nl/. The website contains documentation, tutorials and example scripts. For additional help and advice, join and search the FieldTrip mailing list (http://fieldtrip.fcdonders.nl/discussion_list). There are also regular FieldTrip Workshops available.

For anyone combining analyses in EEGLAB and FieldTrip, the function eeglab2fieldtrip can be extremely useful (http://eeglab.googlecode.com/svn-history/r9697/eeglab/plugins/dipfit2.2/eeglab2fieldtrip.m).

Useful references

Oostenveld, R., Fries, P., Maris, E., Schoffelen, JM (2011) FieldTrip: Open Source Software for Advanced Analysis of MEG, EEG, and Invasive Electrophysiological Data. Computational Intelligence and Neuroscience.

 

SPM (A toolbox for MATLAB)

SPM is a toolbox designed for MRI, EEG and MEG data. The SPM toolbox can be downloaded here: http://www.fil.ion.ucl.ac.uk/spm/. The website contains a manual and wiki.  Useful videos on general and SPM-specific fMRI/MEG/EEG topics can be found here: http://www.fil.ion.ucl.ac.uk/spm/course/video/.  For additional help and advice, join and search the SPM mailing list (http://www.fil.ion.ucl.ac.uk/spm/support/). There are also regular SPM Workshops available.

Useful references

Friston, K.J., Ashburner, J.T., Kiebel, S.J., Nichols, T.E. & Penny, W.D. (2006). Statistical Parametric Mapping: The Analysis of Functional Brain Images, 1st Edition. Academic Press.

Additional references can be found here: http://www.fil.ion.ucl.ac.uk/spm/doc/biblio/Biblio/complete-bibliography.html 

 

ERPLAB (A toolbox for MATLAB)

ERPLAB is a toolbox that works within EEGLAB, and it is designed specifically for ERP data analyses.  The toolbox can be downloaded from the ERPLAB webpage: http://erpinfo.org/erplab. In order to install and use ERPLAB you will first need to have EEGLAB installed.  Like EEGLAB, the ERPLAB functions can be used through the GUI or by scripting.  EEGLAB and ERPLAB functions can be used in conjunction, and many people choose to do some pre-processing steps in EEGLAB and then move the cleaned data into ERPLAB to take advantage of the ERP-specific functions.  The ERPLAB website is full of useful tutorials, videos, scripting guides/examples and FAQs to get you started.

 

Mass Univariate ERP Toolbox (A toolbox for MATLAB)

The Mass Univariate ERP Toolbox is a set of MATLAB functions for performing mass univariate analysis of ERP data.  This method is used to correct for the multiple comparisons problem that occurs when analyzing EEG data with typical hypothesis tests (e.g. t-tests).  The toolbox can be downloaded from the website: http://openwetware.org/wiki/Mass_Univariate_ERP_Toolbox.  The website also includes a tutorial and a link to a series of short videos by David Groppe (one of the Toolbox developers) about statistical methods for EEG analysis.

Useful references

Groppe, D.M., Urbach, T.P., Kutas, M. (2011) Mass univariate analysis of event-related brain potentials/fields I: A critical tutorial review. Psychophysiology. 48(12) pp. 1711-1725. 

 

REMlogic

REMlogic is a piece of software designed for analysing data from sleep EEG. It is not freely-available, but is currently (2013) the software of choice for the York Sleep Lab.

 

Others

There are countless other programs being used and developed. Other toolboxes we've heard used are:

 

Analysis techniques

 

The following sections are intended provide a brief overview of some different types of analyses for EEG data. This is not, however, an extensive list and new methods and publications are coming out all the time. The references are intended to be a starting list for interested individuals and are by no means comprehensive.

 

Pre-processing

Pre-processing is an important start to any EEG analysis. It involves organising and ‘cleaning up’ the raw data.  Many EEG analysis software tools have useful online tutorials that cover software-specific pre-processing steps - see the Analysis section below for links to these tutorials.

Useful references

Delorme, A., & Makeig, S. (2004). EEGLAB: an open source toolbox for analysis of single-trial EEG dynamics including independent component analysis. Journal of neuroscience methods, 134(1), 9–21.

Ille N, Berg P, Scherg M. (2002). Artifact correction of the ongoing EEG using spatial filters based on artifact and brain signal topographies. Journal of Clinical Neurophysiology 19:113-24.

Picton TW, van Roon P, Armilio ML, Berg P, Ille N, Scherg M. (2000). The correction of ocular artifacts: a topographic perspective. Clinical Neurophysiology 111:53-65.

Berg P, Scherg M. (1994). A multiple source approach to the correction of eye artifacts. Electroencephalography & Clinical Neurophysiology 90:229-41.

Litvak V, Komssi S, Scherg M, Hoechstetter K, Classen J, Zaaroor M, Pratt H, Kahkonen S. (2007). Artifact correction and source analysis of early electroencephalographic responses evoked by transcranial magnetic stimulation over primary motor cortex. NeuroImage 37:56–70.

Lins OG, Picton TW, Berg P, Scherg M. (1993). Ocular artifacts in recording EEGs and event-related potentials. II: Source dipoles and source components. Brain Topography 6:65-78.

Delorme A, Palmer J, Onton J, Oostenveld R, Makeig S (2012) Independent EEG Sources Are Dipolar. PLoS ONE 7(2): e30135. doi:10.1371/journal.pone.0030135 


Event-Related Potentials (ERPs)

ERPs are commonly used in the analysis of EEG data. ERPs show activity on the scalp that is time-locked to a stimulus of interest, averaged over a number of trials and/or electrodes. ERPs can be statistically analysed using many different methods. Historically, these were limited to amplitude and/or latency measures and the identification of components. More recently, there has been a surge of interest in other methods, such as those outlined below, although amplitude/latency methods are still common.

The analysis of ERPs is possible in most EEG software and analysis packages.

Useful references

Maris, E. (2012). Statistical testing in electrophysiological studies. Psychophysiology., 49(4):549-65. 


Non-parametric permutation analyses

Non-parametric methods can refer to a variety of different techniques and can be utilised in many different ways. Brain activity data tends to break the ‘rules’ for parametric statistical tests. Cluster-based permutation analyses can be used to overcome the multiple comparisons problem for large datasets.

Video introduction

http://www.cogsci.ucsd.edu/~dgroppe/EEGLAB12_statistics.html 

Useful references

Galán, L., Biscay, R., Rodríguez, J. L., Pérez-Abalo, M. C., & Rodríguez, R. (1997). Testing topographic differences between event related brain potentials by using non-parametric combinations of permutation tests. Electroencephalography and clinical neurophysiology, 102(3), 240–7. Retrieved from http://www.ncbi.nlm.nih.gov/pubmed/9129579

Karniski, W., Blair, R. C., & Snider, a D. (1994). An exact statistical method for comparing topographic maps, with any number of subjects and electrodes. Brain topography, 6(3), 203–10. Retrieved from http://www.ncbi.nlm.nih.gov/pubmed/8204407

Nichols, T. E., & Holmes, A. P. (2002). Nonparametric permutation tests for functional neuroimaging: a primer with examples. Human brain mapping, 15(1), 1–25. Retrieved from http://www.ncbi.nlm.nih.gov/pubmed/11747097

Singh, K. D., Barnes, G. R., & Hillebrand, A. (2003). Group imaging of task-related changes in cortical synchronisation using nonparametric permutation testing. NeuroImage, 19(4), 1589–1601.

Xu, Y., Sudre, G. P., Wang, W., Weber, D. J., & Kass, R. E. (2011). Characterizing global statistical significance of spatiotemporal hot spots in magnetoencephalography/ electroencephalography source space via excursion algorithms. Statistics in medicine, 30(23), 2854–66.

Maris E., Oostenveld R. (2007). Nonparametric statistical testing of EEG- and MEG-data. J Neurosci Methods.


Topographic Analyses

Topographic analysis refers to an analysis of how the amplitude of recorded activity is distributed across scalp electrode locations. Topographic maps typically show a view of the scalp and are shaded according to the amplitude of the activity measured at each electrode. There are several ways in which these maps can be used and/or analysed statistically.

Useful references

Murray, M. M., Brunet, D., & Michel, C. M. (2008). Topographic ERP analyses: a step-by-step tutorial review. Brain topography, 20(4), 249–64.

Skrandies, W. (1990). Global field power and topographic similarity. Brain topography, 3(1), 137–41. Retrieved from http://www.ncbi.nlm.nih.gov/pubmed/2094301

Brunet, D., Murray, M. M., & Michel, C. M. (2011). Spatiotemporal analysis of multichannel EEG: CARTOOL. Computational intelligence and neuroscience, 2011, 813870.


Frequency Analyses

In addition to providing data about where on the scalp and when in time differences in brain activity occur, EEG data can also be separated into different frequency bands for analysis. Different frequency bands have, in the past, been related to cognitive processes and provide a third dimension for EEG analysis. Frequency information can be analysed in combination with electrode and/or timing information. It is possible to analyse the frequencies of induced and evoked activity.

Frequency analyses can be carried out in most of the software described in the ‘Analysis Software’ section below. However, the types of frequency analysis that are possible can vary between software.

Useful references

Mitra PP, Pesaran B. (1999) Analysis of dynamic brain imaging data. Biophys J., 76(2):691-708.

Jarvis MR, Mitra PP. (2001). Sampling properties of the spectrum and coherency of sequences of action potentials. Neural Comput., 13(4):717-49.

Tallon-Baudry C, Bertrand O, Delpuech C, Permier J. (1997). Oscillatory gamma-band (30-70 Hz) activity induced by a visual search task in humans. J Neurosci., 17(2):722-34.


Source Localisation

High-density EEG (typically 64+ channels) can be used to infer the sources of the brain that are active during different experimental conditions. This involves using an inverse model to estimate the activity in the brain that is likely to have produced certain patterns of activity on the scalp. Note that the spatial resolution of this type of analysis is limited in EEG compared to MEG or fMRI, but is nevertheless desirable for some experiments.

Useful references

Michel, C. M., Murray, M. M., Lantz, G., Gonzalez, S., Spinelli, L., & Grave de Peralta, R. (2004). EEG source imaging. Clinical neurophysiology : official journal of the International Federation of Clinical Neurophysiology, 115(10), 2195–222. doi:10.1016/j.clinph.2004.06.001

Dale AM, Liu AK, Fischl B, Buckner RL, Belliveau JW, Lewine JD, Halgren E (2000): Dynamic statistical parametric mapping: combining fMRI and MEG to produce high-resolution spatiotemporal maps of cortical activity. Neuron 26:55-67.

Arthur K. Liu, Anders M. Dale, and John W. Belliveau (2002): Monte Carlo Simulation Studies of EEG and MEG Localization Accuracy. Human Brain Mapping 16:47-62.

Fa-Hsuan Lin, Thomas Witzel, Matti S. Hamalainen, Anders M. Dale, John W. Belliveau, and Steven M. Stufflebeam (2004): Spectral spatiotemporal imaging of cortical oscillations and interactions in the human brain. NeuroImage 23:582-595.

Mosher JC, Lewis PS, Leahy RM. (1992). Multiple dipole modeling and localization from spatio-temporal MEG data. IEEE Trans Biomed Eng., 39(6):541-57.

Mosher JC, Baillet S, Leahy RM. (1999) EEG source localization and imaging using multiple signal classification approaches. J Clin Neurophysiol., 16(3):225-38.

Van Veen BD, van Drongelen W, Yuchtman M, Suzuki A. (1997). Localization of brain electrical activity via linearly constrained minimum variance spatial filtering. IEEE Trans Biomed Eng. 44(9):867-80.

Gross J, Kujala J, Hamalainen M, Timmermann L, Schnitzler A, Salmelin R. (2001). Dynamic imaging of coherent sources: Studying neural interactions in the human brain. Proc Natl Acad Sci USA., 16;98(2):694-9.

Fuchs M, Kastner J, Wagner M, Hawes S, Ebersole J.S. (2002). A standardized boundary element method volume conductor model. Clin Neurophysiol., 113(5):702-12.

Oostendorp T, van Oosterom A. (1991). The potential distribution generated by surface electrodes in inhomogeneous volume conductors of arbitrary shape. IEEE Trans Biomed Eng, 38(5):409-17.

R. Kavanagh, T. M. Darccey, D. Lehmann, and D. H. Fender. (1978). Evaluation of methods for three-dimensional localization of electric sources in the human brain. IEEE Trans Biomed Eng, 25:421-429.


Dipole Fitting

A different method of inferring activity in the brain is to place ‘dipoles’ in certain regions of the brain and to estimate the ‘activity’ in these dipoles from the activity on the scalp.

The BESA Website provides some information about dipole fitting (although note that the BESA software itself is not freely-available). Nevertheless, the BESA Website provides a free dipole simulator tool (http://www.besa.de/updates/tools/).


Dynamic Causal Modelling (DCM)

For an introduction to DCM, check the Scholarpedia page: http://www.scholarpedia.org/article/Dynamic_causal_modeling 

Useful references

Kiebel, S. J., Garrido, M. I., Moran, R. J., & Friston, K. J. (2008). Dynamic causal modelling for EEG and MEG. Cognitive neurodynamics, 2(2), 121–36.

Pinotsis, D. a, Schwarzkopf, D. S., Litvak, V., Rees, G., Barnes, G., & Friston, K. J. (2012). Dynamic causal modelling of lateral interactions in the visual cortex. NeuroImage, 66C, 563–576.