-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbasePreprocessingAltair.m
More file actions
38 lines (26 loc) · 952 Bytes
/
basePreprocessingAltair.m
File metadata and controls
38 lines (26 loc) · 952 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
function [EEG] = basePreprocessingSoar(EEG,bnds)
%John LaRocco
%--------------------------------------------------------------------------
% basePreprocessingSoar
% Last updated: Jan 2024, J. LaRocco
% Details: Function performs preprocessing with baseline removal and detrending.
% Usage: [EEG] = basePreprocessingSoar(EEG)
% Input:
% EEG: a struct of EEG data.
% Output:
% EEG: a struct of final EEG data.
%--------------------------------------------------------------------------
%%Preprocessing
%% Where the file is preprocessed.
%snr0 = snrCompare(EEG.data,bnds,EEG.srate);
EEG = pop_clean_rawdata(EEG,'asr',1);
%EEG = eeg_checkset(EEG); clc;
EEG = removeTrend(EEG); clc;
EEG = soarPreproc(EEG,bnds); clc;
EEG = pop_eegfiltnew(EEG,bnds(1),bnds(2)); clc;
%snr1 = snrCompare(EEG.data,bnds,EEG.srate);
x=EEG.data;
x=smoothdata(x);
EEG.data=x;
EEG = eeg_checkset(EEG); clc;
end