[Eeglablist] Clustering ICs across sessions but within subjects

Ghislain d'Entremont ghislaindentremont at gmail.com
Fri Aug 11 06:55:05 PDT 2017

Hi Tarik, I ran though your code line by line with success. I suppose the
error may have had something to do with my identifying two datasets as
coming from the same subject and having the same ICA decomposition, or with
my identifying two datasets as coming from the same subject but different
sessions and therefore different ICA decompositions.

Your solution appears to be simply to treat every dataset with a unique
subject identifier. Then, as I understand it, you recommend identifying
which ICAs, across subjects or conditions, share substantial similarities.
Presumably if the ICAs from different conditions but within subjects shared
similar ICA decompositions you would consider running a single
decomposition on the aggregate data from those conditions and then do
analyses on those.

Is my summary of your recommendations reasonably accurate?


*Ghislain d'Entremont*
BSc, Neuroscience, Honors
MSc Kinesiology Candidate
Dalhousie University
tel: 902-802-5671 (text)

On Thu, Aug 10, 2017 at 3:07 PM, Tarik S Bel-Bahar <tarikbelbahar at gmail.com>

> Hello Ghislain, a quick followup here:
> Here below is the eegh output for a series of steps I used to get an
> initial ICA cluster for the single-subject's four files you sent.
> I loaded only the  4 .set files,
> then in the Study info gui gave them a unique ID, named them all as the
> same session, condition and group...
> and then ran precomputation for IC info (just spectra and scalp), then IC
> preclustering with defaults for just spectra and scalp info,
> and then clustered with defaults, and it seemed to work. You can give it a
> try with the code below if you point it to the correct folder for loading
> the files. Alternatively you should be able replicate the steps on your own.
> Just first these steps first to force eeglab to cluster the ICs from the
> four files, and then go from there, changing things.
> Although your have sparse-EEG(14 electrodes) and it seems like the
> electrodes are ot necessarily fully correct in terms of their locations
> (they seem all in midline of the head rather than spread out - you can fix
> this in Edit channel locations, to spread them out correctly),
> I do see what seems like an eyeblink IC, a lateral eye movement IC, and
> perhaps a muscle IC or two.
> *****eegh output  below for seemingly successful single-subject,
> multi-condition, IC clustering. Note that you may compute more IC measures,
> do pre-clustering with different settings, and do the IC clustering with
> different settings. Note that I recommend at this stage doing clear visual
> checks of IC component properties from the different files, as a sanity
> check and to familiarize yourself more.
> EEG = pop_loadset('filename',{'raw_I_p102_ME_left.set'
> 'raw_I_p102_ME_right.set' 'raw_I_p102_MI_left.set'
> 'raw_I_p102_MI_right.set'},'filepath','/Users/tarikbel-
> bahar/Downloads/eeglab_reproducible/');
> [ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'study',0);
> [STUDY ALLEEG] = std_editset( STUDY, ALLEEG, 'name','xxx','task','xxx','
> notes','xxx','commands',{{'index' 1 'subject' '103' 'subject' '1'}
> {'index' 2 'subject' '2'} {'index' 3 'subject' '3'} {'index' 4 'subject'
> '4'} {'index' 1 'session' 1} {'index' 2 'session' 1 'condition' 'left'}
> {'index' 3 'condition' 'left'} {'index' 4 'condition' 'left'} {'index' 1
> 'group' '1'} {'index' 2 'group' '1'} {'index' 3 'group' '1'} {'index' 4
> 'group' '1'}},'updatedat','on','savedat','on','rmclust','on' );
> [STUDY ALLEEG] = std_checkset(STUDY, ALLEEG);
> [STUDY ALLEEG] = std_precomp(STUDY, ALLEEG, 'components','allcomps','on','
> recompute','on','scalp','on','spec','on','specparams',{'specmode' 'fft'
> 'logtrials' 'off'});
> [STUDY ALLEEG] = std_preclust(STUDY, ALLEEG, 1,{'spec' 'npca' 10 'norm' 1
> 'weight' 1 'freqrange' [3 25] },{'scalp' 'npca' 10 'norm' 1 'weight' 1
> 'abso' 1});
> [STUDY] = pop_clust(STUDY, ALLEEG, 'algorithm','kmeans','clus_num',  14 );
> STUDY = std_topoplot(STUDY,ALLEEG,'clusters',[2   3   4   5   6   7   8
> 9  10  11  12  13  14  15]);
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sccn.ucsd.edu/pipermail/eeglablist/attachments/20170811/33bdef05/attachment.html>

More information about the eeglablist mailing list