MATLAB: Common average refrencing (CAR) application on EEG signals.

eeg pre-processing

I have a matrix of dimensions 450000*60 of a one class eeg signal. I have to apply Common average referencing (CAR) on it. Matrix dimension 45000*60 where 1:60 is the no. electrodes from 1 to 60 and 45000 is the total number of samples. Each trial consists of 1000 samples. This is to be calculated trial wise Can anybody help me with the code?

Best Answer

You can try
for i=1:60 signal2(:,i)=signal1(:,i)-mean(signal1,2); end
Related Question