[Eeglablist] Error running PCA

Makoto Miyakoshi mmiyakoshi at ucsd.edu
Wed Sep 11 15:48:03 PDT 2019


Dear Matthew,

I added the description about this issue on this page.
https://sccn.ucsd.edu/mediawiki/index.php?title=Makoto%27s_useful_EEGLAB_code&action=submit#How_to_reject_ICs_.2809.2F11.2F2019_updated.29

Makoto

On Wed, Sep 11, 2019 at 12:09 PM Makoto Miyakoshi <mmiyakoshi at ucsd.edu>
wrote:

> Dear Matthew,
>
> pop_subcomp() does not update EEG.icaact! Run eeg_checkset(EEG, 'ica')
> right after pop_subcomp().
>
> Indeed this is very misleading.
>
> Makoto
>
>
>
> On Wed, Sep 4, 2019 at 9:39 AM Gunn, Matthew P <mathewgunn1 at siu.edu>
> wrote:
>
>> Good morning,
>>
>> When running the following commands in a script:
>>
>>    EEG = pop_runica(EEG, 'icatype', 'binica', 'pca',30,'extended',1);
>>    EEG = pop_subcomp( EEG, [1], 0);
>>    EEG = pop_select( EEG,'nochannel',{'OZ'});
>>    EEG = eeg_checkset( EEG );
>>    EEG = pop_runica(EEG, 'icatype', 'binica', 'pca',29,'extended',1);
>>
>> I get the error
>>
>> Error using  *
>> Incorrect dimensions for matrix multiplication. Check that the number of
>> columns in the first matrix
>> matches the number of rows in the second matrix. To perform elementwise
>> multiplication, use '.*'.
>>
>> Error in pop_runica (line 522)
>> meanvar = sum(EEG.icawinv.^2).*sum(transpose((EEG.icaweights *
>>
>> EEG.icasphere)*EEG.data(EEG.icachansind,:)).^2)/((length(EEG.icachansind)*EEG.pnts)-1);
>>
>> Error in Remove_C1_n_PCA29_v1a (line 19)
>> EEG = pop_runica(EEG, 'icatype', 'binica', 'pca',29,'extended',1);
>>
>> I am confused as to why I get this error as the script has worked on
>> other PCs and works when running the command individually in the command
>> window.
>>
>> I am currently using mathlab 2019a and EEGlab 2019
>>
>> Thank you for your time,
>>
>> Matt Gunn
>> _______________________________________________
>> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
>> To unsubscribe, send an empty email to
>> eeglablist-unsubscribe at sccn.ucsd.edu
>> For digest mode, send an email with the subject "set digest mime" to
>> eeglablist-request at sccn.ucsd.edu
>>
>
>
> --
> Makoto Miyakoshi
> Assistant Project Scientist, Swartz Center for Computational Neuroscience
> Institute for Neural Computation, University of California San Diego
>


-- 
Makoto Miyakoshi
Assistant Project Scientist, Swartz Center for Computational Neuroscience
Institute for Neural Computation, University of California San Diego


More information about the eeglablist mailing list