Station 4 · Lesson 7

AMICA & Picard

Optional12 minBefore this lesson: Running ICAPrint the card
Starts from: eeglab_data.set (D1) · Already applied: High-pass & low-pass filtering, Removing line noise (50/60 Hz), Bad channels, Channel interpolation, Re-referencingDownload the data (opens in a new tab)
Script to reach this state
MATLAB
[ALLEEG, EEG, CURRENTSET, ALLCOM] = eeglab;
eeglabRoot = fileparts(which('eeglab'));
EEG = pop_loadset('eeglab_data.set', fullfile(eeglabRoot, 'sample_data'));
fullLocs = EEG.chanlocs;

% Main dataset: high-pass at 0.1 Hz, then 60 Hz line-noise removal
EEG = pop_eegfiltnew(EEG, 'locutoff', 0.1);
EEG = pop_eegfiltnew(EEG, 'locutoff', 58, 'hicutoff', 62, 'revfilt', 1);

% Bad channels you removed earlier, e.g. {'T7'}; leave empty if none
badChans = {};
if ~isempty(badChans)
    EEG = pop_select(EEG, 'rmchannel', badChans);
    EEG = pop_interp(EEG, fullLocs, 'spherical');
end

% Average reference, EOG channels excluded
eogIdx = find(ismember({EEG.chanlocs.labels}, {'EOG1', 'EOG2'}));
EEG = pop_reref(EEG, [], 'exclude', eogIdx);
EEG.filename = ''; EEG.filepath = ''; EEG.datfile = ''; EEG.saved = 'no';
[ALLEEG, EEG, CURRENTSET] = pop_newset(ALLEEG, EEG, 0, 'setname', 'D1 main', 'gui', 'off');
eeglab redraw;

The idea in brief

runica, extended Infomax, is the default ICAA method that separates the recording into independent sources, some brain and some artifact. in EEGLAB and the one on our path. It is not the only choice. Two other algorithms appear often in EEGA recording of the brain's electrical activity from electrodes on the scalp. papers:

Before and after

Image coming soon.

Two rows of scalp maps from D1, the first 10 ICA components of the same 1 Hz copy: the top row from runica, the bottom row from Picard in Infomax mode. The eye component is visible in both rows, possibly at a different position or with flipped colours. Same colormap and scale in both rows. Source: the figures from this lesson’s script.

Your next questions, each answered in its own section:

Why do I need this step?

The reasons in detail, and the terms you need
  • AMICA: EEGLAB lists it in the ICA window as AMICA (slowest; best). It can learn more than one ICA model for the same data.
  • Picard: a faster way to reach an Infomax or FastICA solution. Its Infomax mode is plain Infomax, not the extended Infomax that runica uses on our path. EEGLAB lists it as Infomax picard.m and FastICA picard.m (fastest).

Both are extensions. The ICA window shows an algorithm only when its function exists on your computer, so AMICA and Picard appear in the list only after you install them.

This lesson is optional. Everything else in the roadmap works with runica.

How do I do it in EEGLAB?

9 steps in the menus

Start with the main datasetOne EEG data file loaded in EEGLAB together with its information. D1 main loaded, as in the Starting point.

First: install an pluginA package that adds new functions or menus to EEGLAB.

  1. Open File then Manage EEGLAB extensions.
  2. Search for picard, or for AMICA, select it, and install it. Restart EEGLAB if it asks you to.

Second: Picard from the ICA window

  1. Make an ICA copy filtered at 1 Hz, as in the Running ICA lesson.
  2. Open Tools then Decompose data by ICA. In ICA algorithm to use (click to select), choose Infomax picard.m. The Commandline options (See help messages) field shows 'maxiter', 500, 'mode', 'standard'.
  3. Add the rankThe number of truly independent channels; it drops after interpolation or average reference. to the options yourself: 'maxiter', 500, 'mode', 'standard', 'pca', 31 in D1. With Picard, pop_runica does not check the rank for you.
  4. Press OK, then compare the maps from Plot then Component maps then In 2-D with those from runica.

Third (optional): AMICA

  1. After installing AMICA, open Tools then Run AMICA on the ICA copy.
  2. Make sure the In File: field is empty. If it shows eeglab_data.fdt, clear it, or AMICA reads the original data from disk instead of the ICA copy. Set # PCA Dims.: to the expected rank, 31 in D1, and choose an output folder you can find.
  3. AMICA takes much longer than runica. Leave it running and compare the maps when it finishes.

Whichever algorithm you use, copy the weights to the main dataset the same way as in the 1-Hz filteringApplying a filter to the data. lesson.

How do I write it as code?

The same steps in 19 lines of MATLAB
MATLAB
% The same ICA copy, decomposed by runica and by Picard (Infomax mode)
EEG_ica = pop_eegfiltnew(EEG, 'locutoff', 1);
expectedRank = EEG_ica.nbchan - numel(badChans) - 1;

tic;
EEG_runica = pop_runica(EEG_ica, 'icatype', 'runica', 'extended', 1);
tRunica = toc;

% pop_runica does not reduce the rank for Picard, so pass 'pca' yourself
tic;
EEG_picard = pop_runica(EEG_ica, 'icatype', 'picard', 'maxiter', 500, ...
    'mode', 'standard', 'pca', expectedRank);
tPicard = toc;

fprintf('runica: %.0f s, %d components\n', tRunica, size(EEG_runica.icaweights, 1));
fprintf('Picard: %.0f s, %d components\n', tPicard, size(EEG_picard.icaweights, 1));

% First 10 scalp maps of each, to compare by eye
pop_topoplot(EEG_runica, 0, 1:10);
pop_topoplot(EEG_picard, 0, 1:10);

% AMICA, after installing the AMICA extension; it also needs the rank
% EEG_ica.datfile = '';   % AMICA must use the filtered data in memory, not eeglab_data.fdt on disk
% EEG_amica = pop_runamica(EEG_ica, 'pcakeep', expectedRank, 'outdir', fullfile(pwd, 'amicaout'));

The scriptA MATLAB file of commands that runs processing steps in order. times runica and Picard on the same copy and prints the number of components of each: 31 in D1 for both. The AMICA line is a comment, because it runs only after you install the extension.

Which value should I choose?

Suitable values for your analysis goal
runica (extended Infomax)PicardAMICA
Comes with EEGLABYes, the defaultNo, an extensionNo, an extension
Speed, as EEGLAB labels itThe defaultFastICA picard.m (fastest)AMICA (slowest; best)
What it givesOne ICA modelA plain Infomax (not extended) or FastICA solution, reached fasterOne or more ICA models
Rankpop_runica tries to detect itPass 'pca' yourselfSet the number of components to keep yourself
When to choose itMost studies, and everything on this roadmapMany datasets, or many channels, when time mattersWhen you want the slowest, most careful decompositionBreaking the data down into a set of ICA components. and have the time
Changing the algorithm does not change the rest of the path.

ICLabelA tool that classifies each ICA component into seven classes with a probability for each., removing components, and copying the weights work the same way with any of the three.

How do I check it worked?

4 quick checks
  1. The algorithm appears in ICA algorithm to use (click to select) after you install it.
  2. The number of components is the expected rank: 31 in D1 for each algorithm.
  3. The maps are similar: the eye component appears in both decompositions, possibly at another position.
  4. You noted the time of each algorithm on your computer, from the script.

What mistakes do people make?

5 mistakes and how to avoid them
  • Looking for the algorithm before installing it. The list in Tools then Decompose data by ICA hides any algorithm whose function is not installed.
  • Forgetting the rank with Picard or AMICA. The automatic rank check in pop_runica belongs to runica. With the other two, set the number of components yourself.
  • Expecting identical components. Different algorithms, and even two runs of runica, give components in a different order and sign. Compare them by shape.
  • AMICA reading the file on disk. If the dataset is linked to a .fdt file, AMICA reads that file, not the filtered data in memory. Empty In File:, or set EEG.datfile = '' in a script.
  • Mixing algorithms within one STUDYAn EEGLAB structure that groups many participants' datasets for joint analysis.. Use the same algorithm and settings for every participantThe person whose data were recorded in the study., and write them in Methods.

How do I write it in my paper?

A Methods template: edit the data, settings and versions to match what you ran

A template: edit the data, settings and versions to match what you ran.

Independent component analysis was computed with Picard (Infomax mode, maximum 500 iterations; picard plugin [version], EEGLAB 2026.1; [31] components after PCA reduction to the data rank) on a copy of the data high-pass filtered at 1 Hz, and the resulting weights were applied to the 0.1 Hz high-pass filtered data.

Where can I read more?

3 sources, official docs first

Written for EEGLAB 2026.1 · 2026-10-28

Need help?

Ask, share feedback, or report an error