RESOURCES
For many years now, weâ€™ve been sharing useful resources and media stories related to our research projects. As a leading Science Laboratory in the San Francisco area, itâ€™s important for us to engage with the community and keep them informed about the incredible work and developments theyâ€™re helping to support.
RESOURCES
For many years now, weâ€™ve been sharing useful resources and media stories related to our research projects. As a leading Science Laboratory in the San Francisco area, itâ€™s important for us to engage with the community and keep them informed about the incredible work and developments theyâ€™re helping to support.
Baseline correction of neural signals
Baseline correction
Electroencephalography (EEG) and magnetoencephalography (MEG) signals (among others) might drift over time and different EEG/MEG channels might exhibt such drifts and/or DC (direct current) offsets differently. These drifts and offsets can be due to sweating and skin conductances or other noise sources. In order to investigate the neural response to an event one would thus like to remove these "uninteresting" signals.
The term baseline correction in electroencephalography (EEG) and magnetoencephalography (MEG) refers to the procedure of relativizing the brain signal of interest with respect to a control (baseline) signal (commonly shortly before a stimulus event). It is a very common procedure for the analysis of timedomain data (e.g., eventrelated potentials; ERPs) or timefrequency data (i.e., power obtained from spectral decomposition using, for example, wavelet convolution or Fourier transformation). However, in particular for timefrequency data, there is no consensus on which baseline correction should be used. For timedomain signals, the 'absolute' baseline is commonly used.
Baseline correction: Types
For an additional approach see Grandchamp & Delorme (2011). For timedomain signals, the absolute baseline is the most common correction and should be the default. For timefrequency data, there is not yet a consensus in the literature. Based on the simulations below, the decibel baseline appears to have good properties. Please also see Urbach & Kutas (2006) who have commented on the potential problems using baseline corrections.
In some cases one might be able to replace the timedomain baseline correction by using a highpass filter with a strong DC (direct current) suppression. Papers making use of this approach are, for example, Maess et al. (2006) or Herrmann et al. (2014).
Common types of baseline corrections are (in Matlab syntax, X being the signal and B the baseline):
Absolute baseline:

range: [inf inf]

formula: X  B
â€‹
Relative baseline:

range: [0 inf]

formula: X / B
Relative chance (relchange):

range: [1 inf]

formula: (X / B) / B
â€‹
Decibel baseline (only for power):

range: [inf inf]

formula: 10*log10(X / B)
Baseline correction: Distributions
Baseline corrections might introduce skewed data distributions. The "relative" baseline and the "relchange" baseline appear to be particularly prone to introduce skewed (nonGaussian) data distributions. This might affect data plotting and statistics: linear plotting and parametric statistics might be inappropriate. For the following simulations, the power in the baseline time window (1 to 0 sec.) relative to the power in the time window of interest (0 to 1 sec.) is linearly changed for 1702 power time courses. For half of the time courses, the mean baseline power is larger than the mean power for the time window of interest. For the other half, the mean baseline power is smaller. Four example time courses (out of 1702) are shown on the left.
On the right, the mean baselinecorrected power is plotted for the 1702 power time courses (separately for each baseline). The mean baselinecorrected power of the four time courses (displayed on the left) are colorcoded. The blue and green dots are of particular interested (a large power decrease relative to the baseline [blue] vs. a large power increase relative to the baseline [green]). Although the change for the blue and green time courses are of similar magnitude, the mean baselinecorrected power for the relative and relchange baselines lead to drastic magnitude differences. This is because if the mean baseline power is large relative to the power in the time window of interest, the baselinecorrected power is squeezed into a small range (0 to 1 for relative; 1 to 0 for relchange). This simple simulation shows that depending on the type of baseline correction, the distribution of baselinecorrected power values can be skewed (for further simulations on this see next the section). In this regard, the 'absolute' and 'decibel' baseline corrections have better properties than the 'relative' and 'relchange' baseline corrections.
Baseline correction: Distributions might depend on variance
For additional simulations on distributional changes introduced by baseline corrections, you might be interested in this document which is based on this simulation script. Some of the simulation results are reproduced here:
The plots above show distributions (histograms) of power values for different baseline correction types. The histograms are based on a signal distribution (N=100000; Gaussian noise, with a mean of 10) and a baseline distribution (N=100000; Gaussian noise, with a mean of 5). Standard deviations (relative to the mean; for details see the matlab script) for the distributions were varied (SDx  signal; SDb  baseline). The plots above reflect the changes in the distribution depending on the standard deviations. In particular the power values for relative and relchange baselines can have very skewed distributions after the correction.
Baseline correction: Single trials vs. average
Depending on the research question, single trials or the average across trials might be analyzed. Importantly, baseline correction will produce different results depending on the stage at which the correction is applied (except for the "absolute" baseline). Baseline correction can be applied on single trials before trials are averaged, or trials are averaged first and baseline correction is applied on the averaged signal.
The comparison between the "baseline first" (baseline correction on single trials and then average across trials) versus "baseline second" (average across trials followed by baseline correction) approaches is shown in the following example (Matlab syntax). In the example, X contains two trials (rows) and four time points (columns). The average across the first two of the time points are considering the baseline. Xm is the average across trials, and Bm the baseline for the trial average.
â€‹
Example code:
X = [1 2 3 4; 4 5 6 7] % two trials with 4 time samples; rows refer to trials
B = mean(X(:,[1 2]),2) % the mean of the first 2 time samples = baseline
Xm = mean(X,1) % acrosstrial average
Bm = mean(B,1) % baseline for acrosstrial average
B = repmat(B,1,size(X,2)) % in order for matlab to work, B needs to have the same dimensions as X
% 'absolute' baseline
mean(X – B) == XmBm % same
% 'relative' baseline
mean(X ./ B) ~= Xm./Bm % different
% 'relchange' baseline
mean((XB) ./ B) ~= (XmBm)./Bm % different
% 'decibel' baseline (this baseline is defined only for power)
mean(10*log10(X ./ B)) ~= 10*log10(Xm./Bm) % different