- MNE version: 1.7.1
- operating system: Windows 11
Hi again. I am trying to name my EEG channels and having trouble. I have data where each channel is a different subject, with one stimulus channel and N=11 subjects (12 total). I think I may be misunderstanding how to name them. I tried to name them by subject name, e.g. ‘B99’ and ‘C6’ and so on but that did not work. I read on the github page that the ch_names
function only works if it starts with ‘MEG’ or ‘EEG’, so I tried this:
create metadata
n_channels = 12
ch_names = [
"stim","EEG99","EEG4","EEG6","EEG7","EEG9","EEG10","EEG13","EEG14","EEG16","EEG17","EEG18"
]
ch_types = ["misc"]+["eeg"]*11
sampling_freq = 40 # in Hz
sfreq = sampling_freq
info = mne.create_info(n_channels,ch_types=ch_types,sfreq=sampling_freq)
print(info)
out:
<Info | 7 non-empty values
bads: []
ch_names: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11
chs: 1 misc, 11 EEG
custom_ref_applied: False
highpass: 0.0 Hz
lowpass: 20.0 Hz
meas_date: unspecified
nchan: 12
projs: []
sfreq: 40.0 Hz
Is there a way to custom name my channels? I am very new to python and appreciate any help.