Difference between revisions of "Using BESA to correct blink and EKG artifacts in MEG data"

From BESA® Wiki
Jump to: navigation, search
(Pattern search for blinks and EKG)
(15 intermediate revisions by 2 users not shown)
Line 4: Line 4:
 
|version = 6.1 or higher
 
|version = 6.1 or higher
 
}}
 
}}
 
 
= Using BESA to correct blink and EKG artifacts in MEG data =
 
  
 
Eyeblinks and EKG cause large artifact signals in the magnetometer channels. The artifact correction facilities of BESA can correct these artifacts quite well. The procedure is quite simple for blinks but more complex for EKG. The following text outlines the procedures and current limitations of BESA for artifact correction.
 
Eyeblinks and EKG cause large artifact signals in the magnetometer channels. The artifact correction facilities of BESA can correct these artifacts quite well. The procedure is quite simple for blinks but more complex for EKG. The following text outlines the procedures and current limitations of BESA for artifact correction.
  
The principles of the artifact correction procedure are described in ''Berg, P., Scherg, M. (1994) A multiple source approach to the correction of eye artifacts. Electroenceph. clin. Neurophysiol, 90: 229-241''.
+
The principles of the artifact correction procedure are described in Berg and Scherg (1994).
  
 
In summary, the following steps are required:
 
In summary, the following steps are required:
Line 17: Line 14:
 
* A spatial PCA is performed on the average to identify the main topographies/components of the artifact signal. For blinks, only one topography is required. For EKG, two or three topographies may be required.
 
* A spatial PCA is performed on the average to identify the main topographies/components of the artifact signal. For blinks, only one topography is required. For EKG, two or three topographies may be required.
 
* The topographies/components are combined into a coefficient file (''*.atf''). Using the '''Artifact''' Menu, the ''atf'' file can be loaded and correction switched on. Contrary to the warning message displayed by the ERP module, averaging can be performed using artifact corrected data.
 
* The topographies/components are combined into a coefficient file (''*.atf''). Using the '''Artifact''' Menu, the ''atf'' file can be loaded and correction switched on. Contrary to the warning message displayed by the ERP module, averaging can be performed using artifact corrected data.
* When the average is loaded into the Source Analysis module, the artifact coefficients (saved in the average file) need to be activated. They will then be incorporated into source modelling using subspace projection (SSP – see also papers by Uusitalo et al.). In this case, SSP is equivalent to the “optimized correction method” described in Berg & Scherg (1994).
+
* When the average is loaded into the Source Analysis module, the artifact coefficients (saved in the average file) need to be activated. They will then be incorporated into source modeling using Adaptive, Surrogate or Ssubspace projection (SSP – see also Uusitalo et al. (1997)). Note that SSP approach is not recommended. Usually, for continuous data, the best effect is achieved using the Adaptive method, for ERP Surrogate.
 +
 
 +
'''References'''
 +
* Berg, P., and Scherg, M. A multiple source approach to the correction of eye artifacts, Electroenceph. clin. Neurophysiol., 1994, 90: 229-241.
 +
* Uusitalo, M.A., Ilmoniemi, R.J. Signal-space projection method for separating MEG or EEG into components. Med. Biol. Eng. Comput., 1997, 35: 135-140.
 +
 
  
 
== Pattern search for blinks and EKG ==
 
== Pattern search for blinks and EKG ==
Line 29: Line 31:
 
# Select Search Query ('''Search/Query''')
 
# Select Search Query ('''Search/Query''')
 
# Select Buffer 1 for averaging ('''Tags/Pattern 1''')
 
# Select Buffer 1 for averaging ('''Tags/Pattern 1''')
# [[File:media/EKG_artifacts_in_MEG_data__(1).png|155x101px]]Identify a clear blink signal on the vertical EOG channel. Right-click at the '''onset''' of the blink, and select '''Default Block''' in the dropdown menu. The marked block should look something like this:
+
# Identify a clear blink signal on the vertical EOG channel. Right-click at the '''onset''' of the blink, and select '''Default Block''' in the dropdown menu. The marked block should look something like this: [[File:EKG_artifacts_in_MEG_data__(1).png|75x55px]]
# [[File:media/image2.png|134x72px]]Click once on the VEOG channel label, so that a rightward arrow is displayed (ignore the correlation window that opens on the right):
+
# Click once on the VEOG channel label, so that a rightward arrow is displayed (ignore the correlation window that opens on the right): [[File:EKG_artifacts_in_MEG_data__(2).png|100x55px]]
 
# Press the '''SAW''' button (Search/Average/Write). BESA will start scanning through the file, and it will stop at each occurrence of a blink. Press “Yes” to accept. “No” to reject, or “Stop asking” to let BESA accept everything automatically. Save the result to a file name of your choice (e.g. ''name_artifact.fsg''), labelling the segment, e.g. “blink”.
 
# Press the '''SAW''' button (Search/Average/Write). BESA will start scanning through the file, and it will stop at each occurrence of a blink. Press “Yes” to accept. “No” to reject, or “Stop asking” to let BESA accept everything automatically. Save the result to a file name of your choice (e.g. ''name_artifact.fsg''), labelling the segment, e.g. “blink”.
 +
Note that instead of '''SAW''' the '''SAV''' can be displayed (Search/Average/View). This interaction has exactly the same meaning as '''SAW''' but does not prompt for saving averaged data but just display it in the average buffer. This behaviour can be switched in '''Search''' Menu by checking '''Search, Average, View''' option
  
 
=== EKG ===
 
=== EKG ===
Line 38: Line 41:
 
# Select filters 5-20 Hz. This should generate a fairly clear signal on the EKG.
 
# Select filters 5-20 Hz. This should generate a fairly clear signal on the EKG.
 
# Set the default block epoch so that the R-wave and the T-wave are well inside the epoch. The setting used for blinks may be OK, but you may need to extend the post-cursor interval, e.g. from 400 to 500 ms.
 
# Set the default block epoch so that the R-wave and the T-wave are well inside the epoch. The setting used for blinks may be OK, but you may need to extend the post-cursor interval, e.g. from 400 to 500 ms.
# [[File:media/image3.png|129x89px]]Proceed as with blinks, but selecting Buffer 2 for averaging ('''Tags/Pattern 2'''). Mark a block around the onset of an R-wave. The marked block should look something like this:
+
# Proceed as with blinks, but selecting Buffer 2 for averaging ('''Tags/Pattern 2'''). Mark a block around the onset of an R-wave. The marked block should look something like this: [[File:EKG_artifacts_in_MEG_data__(3).png|100x56px]]
 
# Save the average in the same file as the averaged blinks, labelling the segment, e.g. “EKG”.
 
# Save the average in the same file as the averaged blinks, labelling the segment, e.g. “EKG”.
 
# Select filters 1-30 Hz. Select '''Search/Tagged Events''', and press '''SAW'''. This repeats the average using the tags that were identified during the first step. Opening up the filters ensures that the average includes more of the EKG signal.
 
# Select filters 1-30 Hz. Select '''Search/Tagged Events''', and press '''SAW'''. This repeats the average using the tags that were identified during the first step. Opening up the filters ensures that the average includes more of the EKG signal.
Line 64: Line 67:
 
== Correcting the raw data ==
 
== Correcting the raw data ==
  
* Switch back to the raw data file, and load the ''*.atf'' file you have created ('''Artifact/Load…''').
+
* After defining the artifact coefficients, they are automatically loaded and used for data. Note that you can enable and disable artifact correction by pressing '''CTRL-E''' or by menu '''Artifact/Correct''' you can load the defined artifact coefficient to another data set (i.e. subsequent recording from the same subject within the same session) using ('''Artifact/Load…''') and providing the ''*.atf'' file you have created (by default with the same name as initial datafile)
* Optionally, check that the artifact correction channels are visible (Artifact/View)
+
* Optionally, check that the artifact correction channels are visible (Artifact/View).
* Switch on artifact correction (Artifact/Correct).
+
* The figure below shows the result of correction of channels A75-A148 on a three-second interval containing both EKG and eye activity. The blue label “1” marks the onset of a blink found during pattern search. The red “2” shows the onset of R-waves found during pattern search.
* The figure on the next page shows the result of correction of channels A75-A148 on a three-second interval containing both EKG and eye activity. The blue label “1” marks the onset of a blink found during pattern search. The red “2” shows the onset of R-waves found during pattern search.
+
* Note that correction is quite good, but it is not perfect. In particular, there is some residual eye activity, e.g. around channels A91, A113, A131. It is intended behaviour since the most important during artifact correction is to not distort brain data.
* Note that correction is quite good, but it is not perfect. In particular, there is some residual eye activity, e.g. around channels A91, A113, A131.
+
  
 
{|
 
{|
Line 74: Line 76:
 
! '''corrected'''
 
! '''corrected'''
 
|-
 
|-
| [[File:media/image4.png|57x57px]][[File:media/image5.png|272x802px]]
+
| [[File:EKG_artifacts_in_MEG_data__(4).png|57x57px]][[File:EKG_artifacts_in_MEG_data__(5).png|272x802px]]
| [[File:media/image6.png|273x801px]]
+
| [[File:EKG_artifacts_in_MEG_data__(6).png|273x801px]]
 
|}
 
|}
  
== <br />
+
== Averaging the raw data ==
Averaging the raw data ==
+
When you press the Average button, a warning dialog will appear:
  
You can leave correction on during data averaging. When you press the Average button, a warning dialog will appear:
+
[[File:EKG_artifacts_in_MEG_data__(7).png|539x124px]]
  
[[File:media/image7.png|539x124px]]
 
  
You may select either option. Because of the recent installation of subspace projection (SSP) in the Source Module, the “distorted topographies” in the warning are no longer an issue for source analysis, provided SSP is switched on when the data are sent to the Source Module. The decision has consequences a) if you intend to analyze data waveform amplitudes and/or latencies, and b) if you intend to export the averages for analysis with other software.
+
You can leave artifact correction on during data averaging but it is not recommended.
  
 
==== Option “Yes” – turn off artifact correction ====
 
==== Option “Yes” – turn off artifact correction ====
  
The averaged data will include EKG and eye artifacts, but these artifacts will not cause epochs to be rejected. The same number of epochs will be included in the average whether or not “Yes” or “No” is chosen.
+
The averaged data will include EKG and eye artifacts, but these artifacts will not cause epochs to be rejected. The same number of epochs will be included in the average whether or not “Yes” or “No” is chosen. If you disable artifact correction during averaging you can reapply it using the "Artifact/Load" menu entry or loading artifact topographies later during Source Analysis. this approach assures that source analysis will be not affected by artifact correction and allows for full control of data. (i.e. comparing ERP data with artifact correction on and off, redefining the number of topographies used for artifact correction, and so on)
 
+
You may load the correction coefficients (''*.atf'') for the average, and switch on artifact correction.
+
  
 
==== Option “No” – leave artifact correction on ====
 
==== Option “No” – leave artifact correction on ====
  
The averaged data will be corrected. Each epoch is corrected before being included in the average.
+
The averaged data will be corrected. Since this operation cannot be reverted without recreating the average. Each epoch is corrected before being included in the average.
  
 
==== Artifact options: which correction model? ====
 
==== Artifact options: which correction model? ====
  
[[File:media/image8.png|353x231px]]The result of the correction on the raw data or the averaged data can be slightly different. The effects of correction will also vary, depending on the settings in '''Artifact/Options'''. These differences can be considered as consequences of variations in the “surrogate” or “adaptive” model of brain activity concurrent with the artifact activity (cf. Berg &amp; Scherg 1994). These differences lead to changes in the estimate of the amounts of artifact activity to be removed by correction. If you intend to use the data waveforms outside BESA, and if you don’t use SSP with the artifact coefficients, then the settings in '''Artifact/Options''' become important. In current versions of BESA, these settings are based on EEG amplitude levels. In Konstanz, we generally use the values shown on the right. Note that these values are '''irrelevant''' if we use SSP in Source Analysis.
+
The result of the correction on the raw data or the averaged data can be slightly different. The effects of correction will also vary, depending on the settings in '''Artifact/Options'''. These differences can be considered as consequences of variations in the “surrogate” or “adaptive” model of brain activity concurrent with the artifact activity (cf. Berg &amp; Scherg 1994). These differences lead to changes in the estimate of the amounts of artifact activity to be removed by correction. If you intend to use the data waveforms outside BESA, and if you don’t use SSP with the artifact coefficients, then the settings in '''Artifact/Options''' become important. In current versions of BESA, these settings are based on EEG amplitude levels.  
 +
[[File:EKG_artifacts_in_MEG_data__(8).png|353x231px]]
  
 
== Sending the data to Source Analysis ==
 
== Sending the data to Source Analysis ==
Line 108: Line 108:
 
* If you averaged the uncorrected data, load the saved ''*.atf'' file ('''Artifact/Load…'''), and switch on correction ('''Artifact/Correct''').
 
* If you averaged the uncorrected data, load the saved ''*.atf'' file ('''Artifact/Load…'''), and switch on correction ('''Artifact/Correct''').
  
[[File:media/image9.png|143x158px]]Then mark a time range and send the data to Source Analysis. At the right of the status bar, the text '''ART''' indicates that the artifact components are used in SSP.
+
Then mark a time range and send the data to Source Analysis. At the right of the status bar, the text '''ART''' indicates that the artifact components are used in SSP.
 +
 
 +
[[File:EKG_artifacts_in_MEG_data__(9).png|143x158px]]
  
 
'''Alternatively, if you averaged the uncorrected data, load the average to Source Analysis, and then load the artifact coefficients as part of the dipole model (load or append solution, and use the dropdown list in the File Open box to select ''*.atf'' instead of ''*.bsa''). This approach has the advantage that the source waveforms of the spatial components show the contribution of eye and EKG activity to the model.'''
 
'''Alternatively, if you averaged the uncorrected data, load the average to Source Analysis, and then load the artifact coefficients as part of the dipole model (load or append solution, and use the dropdown list in the File Open box to select ''*.atf'' instead of ''*.bsa''). This approach has the advantage that the source waveforms of the spatial components show the contribution of eye and EKG activity to the model.'''
  
This implicit application of SSP during Source Analysis is mathematically equivalent to the “optimizing” correction method (cf. Berg &amp; Scherg 1994): the topographies of the artifacts are implicitly incorporated into any dipole model.
+
This implicit application of artifact topographies during Source Analysis is mathematically equivalent to the “optimizing” correction method (cf. Berg &amp; Scherg 1994)
  
 
== Limitations of the correction method in BESA ==
 
== Limitations of the correction method in BESA ==
Line 118: Line 120:
 
=== Bad channels ===
 
=== Bad channels ===
  
The ''*.atf'' file contains a two-line header with a) the number of channels, and b) the channel labels. If these do not match with the current data file, artifact correction is not possible. Bad channels are marked (with an asterisk next to the label), and the corresponding coefficient is set to zero. The irritating, but logical, the consequence is that if a channel was excluded (defined as “bad”) when the coefficients were generated, it is not possible to make the channel “good” again.
+
The ''*.atf'' file contains a two-line header with a) the number of channels, and b) the channel labels. If these do not match with the current data file, artifact correction is not possible. Bad channels are marked (with an asterisk next to the label), and the corresponding coefficient is set to zero. The irritating, but logical, consequence is that if a channel was excluded (defined as “bad”) when the coefficients were generated, it is not possible to make the channel “good” again.
  
 
The solution is to regenerate the ''*.atf'' file, making sure the same bad channels are defined in the averaged artifact file as the to-be-corrected raw or average data file. You do not need to regenerate the artifact averages.
 
The solution is to regenerate the ''*.atf'' file, making sure the same bad channels are defined in the averaged artifact file as the to-be-corrected raw or average data file. You do not need to regenerate the artifact averages.

Revision as of 14:59, 2 February 2021

Module information
Modules BESA Research Standard or higher
Version 6.1 or higher

Eyeblinks and EKG cause large artifact signals in the magnetometer channels. The artifact correction facilities of BESA can correct these artifacts quite well. The procedure is quite simple for blinks but more complex for EKG. The following text outlines the procedures and current limitations of BESA for artifact correction.

The principles of the artifact correction procedure are described in Berg and Scherg (1994).

In summary, the following steps are required:

  • Use pattern search and average to identify the latencies of blink/EKG signals in the raw data. Pattern search works best if you have recorded a vertical EOG and EKG with the MEG data, but it will also work on selected MEG channels, using the appropriate filters.
  • A spatial PCA is performed on the average to identify the main topographies/components of the artifact signal. For blinks, only one topography is required. For EKG, two or three topographies may be required.
  • The topographies/components are combined into a coefficient file (*.atf). Using the Artifact Menu, the atf file can be loaded and correction switched on. Contrary to the warning message displayed by the ERP module, averaging can be performed using artifact corrected data.
  • When the average is loaded into the Source Analysis module, the artifact coefficients (saved in the average file) need to be activated. They will then be incorporated into source modeling using Adaptive, Surrogate or Ssubspace projection (SSP – see also Uusitalo et al. (1997)). Note that SSP approach is not recommended. Usually, for continuous data, the best effect is achieved using the Adaptive method, for ERP Surrogate.

References

  • Berg, P., and Scherg, M. A multiple source approach to the correction of eye artifacts, Electroenceph. clin. Neurophysiol., 1994, 90: 229-241.
  • Uusitalo, M.A., Ilmoniemi, R.J. Signal-space projection method for separating MEG or EEG into components. Med. Biol. Eng. Comput., 1997, 35: 135-140.


Pattern search for blinks and EKG

Eyeblinks

  1. Select filters 0.5 – 8 Hz (Filters/Edit Filter Settings…). Make sure the low cutoff filter type is Forward! (This is to ensure that no contribution from the blink topography bleeds back into the baseline time interval).
  2. View Polygraphic signals only (press the Pgr button at the top right of the BESA window), so that the vertical EOG channel is displayed
  3. Define the search block from –100 ms to +400 ms (Edit/Default Block Epoch…)
  4. Select Pattern Search (Search/Pattern)
  5. Select Search Query (Search/Query)
  6. Select Buffer 1 for averaging (Tags/Pattern 1)
  7. Identify a clear blink signal on the vertical EOG channel. Right-click at the onset of the blink, and select Default Block in the dropdown menu. The marked block should look something like this: EKG artifacts in MEG data (1).png
  8. Click once on the VEOG channel label, so that a rightward arrow is displayed (ignore the correlation window that opens on the right): EKG artifacts in MEG data (2).png
  9. Press the SAW button (Search/Average/Write). BESA will start scanning through the file, and it will stop at each occurrence of a blink. Press “Yes” to accept. “No” to reject, or “Stop asking” to let BESA accept everything automatically. Save the result to a file name of your choice (e.g. name_artifact.fsg), labelling the segment, e.g. “blink”.

Note that instead of SAW the SAV can be displayed (Search/Average/View). This interaction has exactly the same meaning as SAW but does not prompt for saving averaged data but just display it in the average buffer. This behaviour can be switched in Search Menu by checking Search, Average, View option

EKG

  1. In contrast to blink averaging we use two steps: first, filters are set to enhance the EKG for pattern search. Second, the filters are opened up, and the average is repeated.
  2. Select filters 5-20 Hz. This should generate a fairly clear signal on the EKG.
  3. Set the default block epoch so that the R-wave and the T-wave are well inside the epoch. The setting used for blinks may be OK, but you may need to extend the post-cursor interval, e.g. from 400 to 500 ms.
  4. Proceed as with blinks, but selecting Buffer 2 for averaging (Tags/Pattern 2). Mark a block around the onset of an R-wave. The marked block should look something like this: EKG artifacts in MEG data (3).png
  5. Save the average in the same file as the averaged blinks, labelling the segment, e.g. “EKG”.
  6. Select filters 1-30 Hz. Select Search/Tagged Events, and press SAW. This repeats the average using the tags that were identified during the first step. Opening up the filters ensures that the average includes more of the EKG signal.

What to do if there is no VEOG or EKG channel

The procedure is similar to the above, but you need to identify a MEG channel that displays the blink or EKG waveform clearly. You may need to experiment with filter settings to make the artifact pattern clearer (the filter settings described above are not fixed rules – you may find that other settings work better for pattern search). You may find the “Create Triggers from EMG/EEG” tool helpful for detecting EKG (ERP/Create Triggers from EMG/EEG…). See the BESA help file (tutorial on creating triggers).

Spatial PCA and the *.atf file

Open the file in which you saved the averages (e.g. name_artifact.fsg). Make sure that prestimulus baseline correction is switched on (Filters/Use Prestimulus Baseline).

Blinks

  1. Mark the whole blink epoch: Right-click onto the epoch, and select Whole Segment.
  2. Select Artifact/Assign/Blink. The spatial PCA is computed, and the first spatial component is assigned to describe the blink. You may check if the correction works by selecting Artifact/Correct.
  3. The coefficients are saved automatically to a file with the same basename as the average, and the extension “.atf”.

EKG

EKG coefficients are corrected analogously to blinks. A difference is that the topographic distribution of the EKG over the MEG sensors is more complex than that of blinks. It changes over time. The reasons for this are unclear, and may be due to movement of the heart (and its equivalent dipoles) over time, but also to ballistic effects: movement of the head due to blood flow.

Since topographic distribution changes over time, more than one component is required for correction. We choose the number of components in the Artifact Select Dialog Box empirically: As a rule of thumb, if a component explains more than 5-10% of the variance of the averaged EKG signal, the component is included. Note that the number of components you select can also be changed when the coefficients are applied to the raw data.

Correcting the raw data

  • After defining the artifact coefficients, they are automatically loaded and used for data. Note that you can enable and disable artifact correction by pressing CTRL-E or by menu Artifact/Correct you can load the defined artifact coefficient to another data set (i.e. subsequent recording from the same subject within the same session) using (Artifact/Load…) and providing the *.atf file you have created (by default with the same name as initial datafile)
  • Optionally, check that the artifact correction channels are visible (Artifact/View).
  • The figure below shows the result of correction of channels A75-A148 on a three-second interval containing both EKG and eye activity. The blue label “1” marks the onset of a blink found during pattern search. The red “2” shows the onset of R-waves found during pattern search.
  • Note that correction is quite good, but it is not perfect. In particular, there is some residual eye activity, e.g. around channels A91, A113, A131. It is intended behaviour since the most important during artifact correction is to not distort brain data.
uncorrected corrected
EKG artifacts in MEG data (4).pngEKG artifacts in MEG data (5).png EKG artifacts in MEG data (6).png

Averaging the raw data

When you press the Average button, a warning dialog will appear:

EKG artifacts in MEG data (7).png


You can leave artifact correction on during data averaging but it is not recommended.

Option “Yes” – turn off artifact correction

The averaged data will include EKG and eye artifacts, but these artifacts will not cause epochs to be rejected. The same number of epochs will be included in the average whether or not “Yes” or “No” is chosen. If you disable artifact correction during averaging you can reapply it using the "Artifact/Load" menu entry or loading artifact topographies later during Source Analysis. this approach assures that source analysis will be not affected by artifact correction and allows for full control of data. (i.e. comparing ERP data with artifact correction on and off, redefining the number of topographies used for artifact correction, and so on)

Option “No” – leave artifact correction on

The averaged data will be corrected. Since this operation cannot be reverted without recreating the average. Each epoch is corrected before being included in the average.

Artifact options: which correction model?

The result of the correction on the raw data or the averaged data can be slightly different. The effects of correction will also vary, depending on the settings in Artifact/Options. These differences can be considered as consequences of variations in the “surrogate” or “adaptive” model of brain activity concurrent with the artifact activity (cf. Berg & Scherg 1994). These differences lead to changes in the estimate of the amounts of artifact activity to be removed by correction. If you intend to use the data waveforms outside BESA, and if you don’t use SSP with the artifact coefficients, then the settings in Artifact/Options become important. In current versions of BESA, these settings are based on EEG amplitude levels. EKG artifacts in MEG data (8).png

Sending the data to Source Analysis

When the average is generated, the correction coefficients are saved in the *.fsg file. Before you send the data to the Source Module, these coefficients must be activated.

  • If you averaged the corrected data, coefficients are already activated. This should be apparent from the red “corrected” displayed above the channel labels.
  • If you averaged the uncorrected data, load the saved *.atf file (Artifact/Load…), and switch on correction (Artifact/Correct).

Then mark a time range and send the data to Source Analysis. At the right of the status bar, the text ART indicates that the artifact components are used in SSP.

EKG artifacts in MEG data (9).png

Alternatively, if you averaged the uncorrected data, load the average to Source Analysis, and then load the artifact coefficients as part of the dipole model (load or append solution, and use the dropdown list in the File Open box to select *.atf instead of *.bsa). This approach has the advantage that the source waveforms of the spatial components show the contribution of eye and EKG activity to the model.

This implicit application of artifact topographies during Source Analysis is mathematically equivalent to the “optimizing” correction method (cf. Berg & Scherg 1994)

Limitations of the correction method in BESA

Bad channels

The *.atf file contains a two-line header with a) the number of channels, and b) the channel labels. If these do not match with the current data file, artifact correction is not possible. Bad channels are marked (with an asterisk next to the label), and the corresponding coefficient is set to zero. The irritating, but logical, consequence is that if a channel was excluded (defined as “bad”) when the coefficients were generated, it is not possible to make the channel “good” again.

The solution is to regenerate the *.atf file, making sure the same bad channels are defined in the averaged artifact file as the to-be-corrected raw or average data file. You do not need to regenerate the artifact averages.

EKG correction is difficult because the topographic distribution of EKG signals is close to some MEG distributions: for instance, we sometimes observe a considerable reduction in alpha amplitudes with EKG correction. For event-related averaging, an EKG correction is often unnecessary, because the EKG is not synchronized with the stimulus.