FastICA
This function runs FastICA using some common settings applied for TMS-EEG data analysis. See the publications listed below for further details. tesa_fastica uses EEGLAB pop_runica function. A stabilization option is also included which can help if data are not converging.
Note that this script requires that the FastICA algorithm is included in the Matlab path. The package can be downloaded from: http://research.ics.aalto.fi/ica/fastica/code/dlcode.shtml
After running FastICA, this function also ranks and sorts the components by percentage variance explained by each time course.
After running this function, independent components representing artifacts can be automatically detected using the automatic component selection function.

EEGLAB user interface

1. Select the approach for FastICA from the drop down menu. The symmetric approach is more stable and is therefore recommended.
2. Select the contrast function (g) from the drop down menu.
3. Turn on or off the stabilization version of the FastICA algorithm. This can help if FastICA is not converging. See the FastICA help for further information.

Scripts

Base function

EEG = tesa_fastica( EEG ); Default use
EEG = tesa_fastica( EEG, 'key1',value1... ); Custom input

Pop function

EEG = pop_tesa_fastica( EEG ); Pop up window
EEG = pop_tesa_fastica( EEG, 'key1',value1... ); Custom input

Required inputs

Input
Description
Example
Default
EEG
EEGLAB EEG structure
EEG
-

Optional inputs (key/value pairs)

Key
Input value
Description
Example
Default
'approach'
'symm' or 'defl'
Symmetric or deflation approach for FastICA. The symmetric approach is more reliable and therefore highly recommended. See Korhonen et al for details.
'symm'
'symm'
'g'
'tanh' or 'gauss' or 'pow3' or 'skew'
Contrast function for FastICA. Either 'tanh' or 'gauss' perform equally well for TMS-EEG analysis. See Korhonen et al for details.
'gauss'
'tanh'
'stabilization'
'on' or 'off'
Controls whether FastICA uses stabilized version which detects 'strokes' (i.e. when algorithm gets stuck between 2 points and won't converge) and halves the learning rate.
'on'
'off'

Outputs

Output
Description
EEG
EEGLAB EEG structure

Examples

EEG = pop_tesa_fastica( EEG ); Default use
EEG = pop_tesa_fastica( EEG, 'g', 'gauss', 'stabilization', 'on' ); Uses the gauss contrast function and turns on the stabilized FastICA version to aid with convergence.
Last modified 1yr ago