Level 7 L7.7

Simultaneous and multimodal EEG (overview)

EEG–fMRI, EEG–TMS and EEG–eye-tracking setups, their artifacts, and the corrections that exist.

~30 min

Prerequisites: L2.8 · Pipeline order and reproducibility

1 claim on this page is unverified. TODO(confirm) marks a specific statement the author has not yet checked against a primary source. Everything else on this page has been reviewed. Treat a marked claim as provisional and go to the cited source rather than quoting the sentence.

Objectives

  • Describe the EEG–fMRI, EEG–TMS and EEG–eye-tracking recording setups
  • Name the artifact each modality introduces and the mechanism that produces it
  • Know which corrections exist (gradient, BCG, TMS pulse) and what each leaves behind
  • State what this site can and cannot show you about these artifacts, and where to look instead

Why this matters

Recording EEG at the same time as another instrument buys something no single modality has: the time resolution of EEG with the spatial resolution of MRI, a causal perturbation with a readout, or eye position aligned to the trace that eye movements contaminate. It also puts the EEG amplifier inside the other instrument’s field, and every one of these setups produces an artifact far larger than the brain signal. This is a 30-minute overview: what the setups are, what each artifact is, which corrections exist, and what each correction leaves behind.

Warning

These artifacts are described here, not shown. This site holds no simultaneous EEG–fMRI, EEG–TMS or EEG–eye-tracking recording, and no dataset in its directory whose licence permits shipping a snippet contains a marked gradient artifact, a ballistocardiogram or a TMS pulse. Simulating one would mean drawing a plausible picture of the exact thing this lesson is teaching you to recognise, which would be a fabrication however clearly labelled — so nothing is drawn. Read the descriptions against real data of your own or against the figures in the correction methods’ own papers, and treat the directory pointers at the end of this lesson as what they are: recordings that are related to these designs without being any of them.

Concepts

EEG inside an MRI scanner

The setup. An MR-compatible cap and amplifier go inside the bore with the participant. The amplifier is non-magnetic and battery-powered, leads are kept short, bundled and routed along the bore axis to minimise loop area, and current-limiting resistors sit at every electrode to limit the induced currents that would otherwise heat the skin. The amplifier’s clock is normally synchronised to the scanner’s gradient clock, and the scanner emits a trigger at every volume or slice. That synchronisation is not a convenience: the correction depends on it.

Artifact 1 — the gradient artifact. Switching magnetic field gradients induce voltages in every conductive loop the setup contains, including the loop made by the leads, the head and the electrodes. The result is a periodic waveform locked to the imaging sequence, repeating at the slice and volume rates, and vastly larger than any cortical signal. TODO(confirm): the usual figure quoted for the ratio is orders of magnitude, but this site has not measured it and carries no source for a specific number, so none is given here. Two practical consequences follow from the size alone: the amplifier must have enough dynamic range and a high enough sampling rate not to clip or alias the artifact, and any saturation is unrecoverable, because a clipped sample no longer contains the sum you intend to subtract from.

Artifact 2 — the ballistocardiogram (BCG). Even between gradient switches, the heartbeat moves the head and the leads slightly within the static field, and blood flow in a conductive medium in a magnetic field produces potentials directly. The result is a roughly once-per-second waveform locked to the cardiac cycle, smaller than the gradient artifact and much harder to remove, because its shape is not stable: it varies with heart rate, with head position, and between electrodes. It sits squarely in the frequency range EEG researchers care about most.

The corrections, and what they leave behind.

  • Gradient: average artifact subtraction — build a template from many repetitions of the artifact, aligned on the scanner triggers, and subtract it epoch by epoch, then low-pass and downsample. This is what the EEGLAB fMRIb plugin’s pop_fmrib_fastr implements (the sidebar names it). It works because the artifact is highly repeatable and precisely timed. It leaves a residual wherever the artifact is not repeatable: participant movement between volumes, drift between the amplifier’s clock and the scanner’s, and the first and last epochs of a run.
  • BCG: detect the heartbeat, usually from a recorded ECG channel (pop_fmrib_qrsdetect), then subtract a template or a set of basis components aligned to it (pop_fmrib_pas), or remove BCG components identified by ICA. Because the artifact’s shape varies, every one of these leaves a residual, and the residual is cardiac-locked — so any analysis of a rhythm near the heart rate, or of anything that correlates with arousal, has to state how BCG was handled and what was left.
  • The general lesson: a correction that subtracts a template removes the repeatable part of an artifact and leaves the part that varied. That residual is structured, not random, so it does not average away, and it is correlated with physiology.

EEG with TMS

The setup. A stimulating coil discharges over the scalp while EEG records. The amplifier must survive a large, fast pulse — either by blanking its input around the pulse (sample-and-hold) or by having enough range and speed to ride through it.

The artifacts, which are several things people bundle under one name.

  • The pulse artifact itself: an enormous, brief transient at the moment of discharge, which saturates unprotected amplifiers.
  • A decay artifact after it, lasting far longer than the pulse, arising from polarisation at the electrode–skin interface and the amplifier’s recovery.
  • A cranial muscle response: the coil stimulates scalp muscle as well as cortex, producing a large EMG deflection over the stimulated site.
  • Sensory co-stimulation: the coil clicks, and it taps the scalp. Both evoke genuine brain responses that have nothing to do with the cortical stimulation, which is why realistic sham conditions and masking noise are part of the design rather than an optional extra.

The corrections. Blanking or interpolating the saturated window; removing the decay and muscle components with ICA or with signal-space projection methods designed for this artifact; and — for the sensory part — controls rather than filters, because a real auditory evoked potential cannot be told from a real auditory evoked potential. FieldTrip’s ft_artifact_tms (named in the sidebar) marks the pulse windows. The residual to state: the interpolated window contains no data at all, so any latency inside it is unmeasured, and the boundary of the interpolated segment is a discontinuity that later filtering will ring across (pf-filter-across-boundaries, L7.3).

EEG with eye tracking

The setup. A video eye tracker records gaze position and pupil size alongside EEG, with a shared clock or a common trigger stream; the two are aligned offline and the alignment is checked, because a constant offset between them looks exactly like a latency effect.

The artifacts, and the reason this pairing is different from the other two. Eye movements produce two things in the EEG: the corneo-retinal dipole rotating, which is a large low-frequency deflection, and the saccadic spike potential, a very brief transient at saccade onset generated by the extraocular muscles, largest at frontal and temporal sites and broadband — which is why uncorrected microsaccades can masquerade as gamma (pf-muscle-as-gamma).

What makes the pairing different is that here the second instrument measures the artifact’s cause. In the fMRI and TMS cases the other instrument creates the artifact; in eye tracking it explains it. That turns a nuisance into a regressor: saccade onsets become events, so ocular contributions can be modelled and removed by deconvolution rather than filtered away, and the eye data double as a check that a “condition effect” is not a difference in looking behaviour. FieldTrip’s ft_detect_movement detects the eye movements from the eye channels; ft_removetemplateartifact subtracts a template time-locked to events of this kind. The residual to state: correction quality depends on the number of saccades observed, and a participant who moves their eyes differently between conditions has a condition-correlated residual after any correction.

What this site holds, and why none of it is one of these designs

The directory has five entries worth knowing about here. None of them is a simultaneous recording of the kind this lesson describes, and the distinction matters:

EntryWhat it actually isWhy it is not a source of these artifacts
ds-respectThe same 6.5-minute film task in iEEG and in fMRI, in overlapping patients — 51 with iEEG, 30 with fMRI, 18 with bothTwo recordings of the same task, not one recording in two modalities at once. Also intracranial, so it has neither a scalp cap nor a gradient artifact
ds-pearl-neuroEEG and MRI in the same 79 participantsSeparate sessions. The EEG has no online notch and a 280 Hz low-pass — a clean scalp recording, made outside a scanner
ds-lemonEEG with MRI in the same cohortSame reason. Its EEG is the site’s resting-state spine, recorded in an EEG lab
ds-chbmpEEG with MRISame reason, and it is behind a registration with a non-commercial licence, so nothing derived from it ships here
ds-physfEEG with a wrist sensor and a respiration belt — genuinely simultaneous, and genuinely multimodalThe closest thing here to a simultaneous multimodal recording; the other two instruments are passive sensors rather than sources of a field the EEG amplifier has to survive. It is available on request, with no licence text, so this site ships nothing from it

The honest summary: simultaneity is the hard part, and it is the part none of these entries has. Two recordings of the same people in two instruments answer some of the same questions and none of the artifact questions, and a lesson that blurred the two would teach you to shop for the wrong dataset.

Explore

No widget. Fifteen minutes with the dataset pages is the exercise, and it is a real one:

  • Open the five entries in the table above and, for each, find the sentence that tells you whether the two modalities were recorded at the same time. Some say so directly; for others you have to read the acquisition table and the paradigm description and infer it. Noticing that the answer is sometimes not stated is part of the point.
  • For each entry, write down what you could do with it that needs both modalities — and what you could not.
  • Then take a design you would like to run, and write the artifact you would have to correct, the correction you would use, the residual that correction leaves, and the control condition that would tell you whether the residual mattered. If you cannot name the residual, you do not yet understand the correction.

Practice

There is no notebook for this module, by design and by circumstance. §6 specifies none, and there is nothing here to compute: this site holds no recording that contains any of these artifacts, so a notebook could only simulate one, which is precisely what this lesson will not do. Instead, read the documentation of the corrections themselves — the function names in the In other tools sidebar below are verified, and each one’s own help text and reference paper is where the artifacts are actually pictured.

Exercises

Exercise ex-7-7-match-artifact-modality

Multiple choice

Match each artifact to the simultaneous-recording setup that produces it. Which assignment is correct throughout?

Options

Exercise ex-7-7-corrections-residuals

Multiple select

Which of these statements about the corrections are true as this lesson describes them?

Options (select all that apply)

Exercise ex-7-7-no-simultaneous-data

Multiple choice

You want to practise gradient-artifact correction on real data, and you start from this site's directory. Which entry gives you a recording containing a gradient artifact?

Options

Pitfalls

No pitfall for this lesson: Spec §6 lists no pitfall for this lesson (§5.3 exemption).

In other tools

In other toolsEEGLAB · FieldTrip — names only

The equivalents of what this lesson does, for a reader who works in another toolbox. Function names only: their own documentation is the place to learn how to call them.

EEGLAB

  • pop_fmrib_fastrfMRIb plugin (install separately)
  • pop_fmrib_qrsdetectfMRIb plugin (install separately)
  • pop_fmrib_pasfMRIb plugin (install separately)

FieldTrip

  • ft_artifact_tmsFieldTrip
  • ft_detect_movementFieldTrip
  • ft_removetemplateartifactFieldTrip

Names checked 2026-09-18 against EEGLAB 2026.0.0 (plugins at the versions in EEGLAB’s own plugin list) and FieldTrip 20251218.

Reading

  1. Gramann et al. (2014). Mobile brain/body imaging. unverified