EEG Virtual channels

Initialize NeuroAnalyzer
using NeuroAnalyzer
eeg = load("files/eeg.hdf")

EEG Virtual Channels are computationally derived channels created by combining existing EEG channels using mathematical operations.

Unlike physical channels (recorded directly from electrodes), virtual channels are synthesized from the raw EEG data. They are widely used in EEG preprocessing, source localization, connectivity analysis, and brain-computer interfaces (BCIs).

Purpose Description
Improve Signal Quality Reduce noise, artifacts, or volume conduction effects.
Enhance Spatial Resolution Create focal derivations (e.g., Laplacian) to localize brain activity.
Extract Features Derive new signals (e.g., alpha/beta power, phase synchronization).
Reduce Data Dimensionality Combine channels to reduce redundancy and focus on relevant features.
Source Localization Represent virtual sources (e.g., dipole moments, beamformer outputs).
Connectivity Analysis Compute functional or effective connectivity between regions.

Keypoints

  • All standard Julia math operators are available.
  • Channel labels must be the same as of the OBJ object.

Examples

Laplacian Derivation

Purpose: Enhance local cortical activity and reduce volume conduction from distant sources.

Steps:

  1. Select a channel (e.g., Cz).
  2. Identify neighboring channels (e.g., C3, C4, Fz, Pz).
  3. Compute the weighted average of the neighbors.
  4. Subtract this average from the central channel.

Formula:

\[ V_{\text{Laplacian}}(i) = V(i) - \frac{1}{N} \sum_{j \in \text{neighbors}} V(j) \]

where:
\(V(i)\) is the voltage at channel \(i\),
\(N\) is the number of neighboring channels.

Example: Cz Laplacian:

\[ V_{\text{Laplacian}}(\text{Cz}) = V(\text{Cz}) - \frac{1}{4} [V(\text{C3}) + V(\text{C4}) + V(\text{Fz}) + V(\text{Pz})] \]

Implementation:

vch(eeg, f = "Cz - mean(C3 + C4 + Fz + Pz)")

Bipolar Montage

Purpose: Highlight local activity by subtracting adjacent channels.

Steps:

  1. Select two adjacent channels (e.g., Fp1 and F7).
  2. Subtract the voltage of the second channel from the first.

Formula:

\[ V_{\text{Bipolar}}(i) = V(i) - V(j) \]

where \(j\) is a neighboring channel.

Example: Fp1-F7 Bipolar:

\[ V_{\text{Bipolar}}(\text{Fp1-F7}) = V(\text{Fp1}) - V(\text{F7}) \]

Implementation:

vch(eeg, f = "Fp1 - F7")