next up previous contents
Next: Correction examples Up: Automatic Artifact Removal (AAR) Previous: Algorithms based on the   Contents


EOG and EMG removal using spatial filters

The toolbox implements a spatial filtering framework for removing different types of artifacts. This framework consists on three basic steps. First, the original EEG data is decomposed into a set of spatial components. Second, artifactual components are identified using a suitable automatic criterion. Third, the EEG data is reconstructed by projecting back to the electrodes only the non-artifactual spatial components. Within this framework, many artifact removal algorithms can be defined by defining the way the spatial components are estimated and by defining the criterion used for identifying artifactual components. The default installation of the toolbox can decompose the EEG data into a set of spatial components using:

The criteria that are included in the current version of the toolbox are:

By default, the toolbox uses a combination of iWASOBI and the criterion eog_fd to automatically correct EOG artifacts in the EEG. This default combination can be called from the EEGLAB menu ''Remove EOG using BSS'', which opens a dialog like in Fig. 6. Using the graphical interface, the user can specify the length and shift between correlative analysis windows. A window shift of 1 second and a window length of 2 seconds means that the first analysis window (on which the BSS-based spatial filters will be obtained) will cover the time range 0-2 seconds, the second analysis window will correspond to the time range 1-3 seconds, the third window will cover the time 2-4 seconds and so on. Note that the optimum window temporal range would be that that covers enough data samples to learn the artifactual spatial components and as few as possible neural EEG components. Therefore, there is no easy and objective way of selecting the optimum window length. If our artifacts have relatively stable spatial patterns (e.g. EOG artifacts) a longer window length might be more appropriate. However, a too long window might cause removal of some EEG components due to the low spatial resolution of the EEG recordings. If our artifacts have relatively short duration (e.g. sudden EMG bursts), a short analysis window might be more appropriate.

Additionally, the user can pass extra parameters to the BSS algorithm and to the criterion. A parameter that is common to all BSS algorithms is 'eigratio', which determines the number of principal components that will be kept in the pre-processing PCA step which is performed before any BSS algorithm. The number of PCA components will be such that the ratio between the largest and smallest eigenvalue of the PCA-transformed data matrix is below the specified 'eigratio'. A large 'eigratio' will most likely not remove any principal component but might lead to numerical unstability of the BSS algorithm due to an ill-conditioned covariance matrix. By contrary, a small value of 'eigratio' will cause some inaccuracies due to the removal of some principal components but will enforce the data covariance matrix to be well-conditioned. By default the 'eigratio' is 1e6.

An important option that can be passed to all available rejection criteria is the 'range' of components that should be removed. That range specifies the minimum and maximum number of components that are to be marked as artifactual in each analysis window. A range like [5,5] enforces the rejection of the 5 components ranked as most likely to be artifactual by the respective criterion. Indeed, increasing the number of rejected components allows for removing more EOG but increases the chances of removing also useful EEG activity of neural origin. If the user selects the criterion eog_corr, the index of at least a reference EOG channel must be provided through the graphical interface.

Figure 6: Interface window for EOG removal using spatial filters.
Interface window for EOG removal using spatial filters.

EMG correction can be performed by selecting the EEGLAB menu ''remove EMG using BSS'', which opens an interface window as in Fig. 7. By default, the BSS algorithm used is based on CCA as in [5]. Currently, the only automatic criterion that can be used for detecting EMG components is emg_psd. The option 'range' allows to reject a fixed number of components in each analysis window, as explained above. Another important parameter of the emg_psd criterion is the ratio of average power in the typical EEG band and in the typical EMG band. For instance, the option 'ratio',10 makes the criterion to mark as EMG-related only those components having less than 10 times more average power in the EEG band than in the EMG band. The boundary between EEG and EMG bands can be specified using the parameter 'femg'. The sampling rate of the data also needs to be specified using the parameter 'fs'. The user can also specify with the parameter estimator, the type of spectral estimator that will be used to estimate the power in the EEG and EMG bands. By default the estimator used is a Hamming-windowed Welch periodogram with segment length equal to the analysis window length. You can check the help of the MATLAB function implementing the different criteria and BSS algorithms for more details on the available options.

Figure 7: Interface window for EMG removal using spatial filters.
Interface window for EMG removal using spatial filters.


next up previous contents
Next: Correction examples Up: Automatic Artifact Removal (AAR) Previous: Algorithms based on the   Contents
gomezher 2007-12-10