File Exchange

image thumbnail

Regularized Common Spatial Pattern with Aggregation (R-CSP-A) for EEG Classification

version 1.0.0.0 (2.2 MB) by Haiping Lu
The codes implement the Regularized Common Spatial Pattern with Aggregation (R-CSP-A) algorithm.

5 Downloads

Updated 19 Mar 2012

View License

Matlab source codes for Regularized Common Spatial Pattern with Aggregation (R-CSP-A)

%[Algorithm]%

The matlab codes provided here implement the R-CSP-A algorithm presented in the
paper "R-CSP-A_TBME2010.pdf" included in this package:

Haiping Lu, How-Lung Eng, Cuntai Guan, K.N. Plataniotis, and A.N. Venetsanopoulos,
"Regularized Common Spatial Pattern With Aggregation for EEG Classification
in Small-Sample Setting",
IEEE Trans. on Biomedical Engineering,
Vol. 57, No. 12, pp. 2936-2946, Dec. 2010.

The following is an earlier conference version "RCSP_EMBC09.pdf"

Haiping Lu, K.N. Plataniotis, and A.N. Venetsanopoulos,
"Regularized Common Spatial Patterns with Generic Learning for EEG Signal Classification",
in Proceedings of the 31st Annual International Conference of the
IEEE Engineering in Medicine and Biology Society (EMBC), Sep., 2009.

[Files]
RegCsp.m: the Regularized Common Spatial Pattern (R-CSP) algorithm
demoR-CSP-Aggr.m: sample code for R-CSP aggregation
FDA.m: perform Fisher’s discriminant analysis (FDA)
---------------------------

%[Usages]%

Please refer to "demoR-CSP-Aggr.m" for example usage
---------------------------

%[Restriction]%

In all documents and papers reporting research work that uses the matlab codes
provided here, the respective author(s) must reference the following paper:

[1] Haiping Lu, How-Lung Eng, Cuntai Guan, K.N. Plataniotis, and A.N. Venetsanopoulos,
"Regularized Common Spatial Pattern With Aggregation for EEG
Classification in Small-Sample Setting",
IEEE Trans. on Biomedical Engineering,
Vol. 57, No. 12, pp. 2936-2946, Dec. 2010.
---------------------------

%[Additional Resources]%

The BibTeX file "RCSPpublications.bib" contains the BibTex for R-CSP-A and
related works. A related work "UMLDA_TNN09.pdf" is included too.
---------------------------

Cite As

Haiping Lu (2021). Regularized Common Spatial Pattern with Aggregation (R-CSP-A) for EEG Classification (https://www.mathworks.com/matlabcentral/fileexchange/35734-regularized-common-spatial-pattern-with-aggregation-r-csp-a-for-eeg-classi-cation), MATLAB Central File Exchange. Retrieved .

Comments and Ratings (7)

Can anyone please provide codes for multiclass CSP algorithm,

Asadur Rahman

Peter Wang

Professor Lu, I have the same question, How to form a 3D array of input data from the BCI Competition dataset IVA?
Thanks

amin

Hello professor Haiping Lu

I have some questions about the implementing the code, it takes much time for me, would you please guide me?

According to the paper, two parameters are named training trials and training sample. What you mean by training samples that value 100 has the best result? (Line 59, according to paper, what does training sample for value 2 mean?)

What was the window or segment length to extract the features, I mean that the start of cue is determined but where is the end (for example 100 msec later).

The third question is in line 63, fea2D_Train = EEG(:,:,trainIdx)
If EEG is the raw data and trainIdx is the label for train.
How is it possible label the eeg data? Label should be used for features not for the sample base data. You know the lengths are not the same. Maybe I did not get the idea.

best Regards
Amin

Email amin_hm2002@yahoo.com

Sujeet Blessing

How to form a 3D array of input data from the BCI Competition dataset IVA??

Haiping Lu

To Amir: "ftrs" are the features and gnd are the corresponding labels. Please refer to line 87-95 of demoR-CSP-Aggr.m for an example. Thanks!

amir tabatabaee

hi , about that fda.m can u tell me what are ftrs and gnd??

MATLAB Release Compatibility
Created with R2006a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!