-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathA_merge_sets.m
66 lines (66 loc) · 5.59 KB
/
A_merge_sets.m
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
% EEGLAB merge sets
% ------------------------------------------------
[ALLEEG EEG CURRENTSET ALLCOM] = eeglab;
EEG = pop_biosig('filepath_to_your_files\Participant_ID_450_1.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_450_1','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_450_1.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_450_2.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_450_2','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_450_2.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_900_1.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_900_1','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_900_1.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_900_2.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_900_2','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_900_2.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_900_3.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_900_3','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_900_3.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_900_4.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_900_4','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_900_4.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_1.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_1','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_1.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_2.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_2','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_2.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_3.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_3','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_3.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_4.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_4','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_4.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_5.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_5','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_5.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_6.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_6','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_6.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_7.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_7','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_7.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = pop_biosig('filepath_to_your_files\Participant_ID_1800_8.edf', 'ref',[67 68] ,'refoptions',{'keepref' 'off'});
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 0,'setname','Participant_ID_1800_8','gui','off');
EEG = pop_saveset( EEG, 'filename','Participant_ID_1800_8.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
EEG = eeg_checkset( EEG );
EEG = pop_mergeset( ALLEEG, [1 2 3 4 5 6 7 8 9 10 11 12 13 14], 0);
[ALLEEG EEG CURRENTSET] = pop_newset(ALLEEG, EEG, 1,'setname','Participant_ID','gui','off');
EEG = eeg_checkset( EEG );
EEG = pop_saveset( EEG, 'filename','Participant_ID.set','filepath','filepath_to_your_files\\');
[ALLEEG EEG] = eeg_store(ALLEEG, EEG, CURRENTSET);
[ALLEEG EEG CURRENTSET ALLCOM] = eeglab;