-
Couldn't load subscription status.
- Fork 262
Description
Description
I am not too sure if this is an issue or I misunderstood how to use eeg_regepochs.
After applying average reference to my continuous data, the epoch start (sec) is 0 and epoch end (sec) is 432.660.
I wanted to split the data into 10 seconds epochs so I tried using eeg_regepochs to split it.
I was hoping it will be divided into 43 epochs with each epoch start to be 0 and end to be 10.
It did get divided into 43 epochs with start of 0 but the epoch end was 0.996 instead of anywhere near 10 secs which seemed odd.
Screenshot links
before_epoch_screenshot
after_epoch_screenshot
I've uploaded the dataset I tried using eeg_regepochs on. Steps has been applied until average reference step using the code below before saving.
Example Dataset
#### Steps to Reproduce
-
Downsample data to 250
EEG = pop_resample( EEG, 250); -
Bandpass filter using IIR Butterworth filter in ERPLAB (1-30)
EEG = pop_basicfilter( EEG, 1:128 , 'Boundary', 'boundary', 'Cutoff', [ 1 30], 'Design', 'butter', 'Filter', 'bandpass', 'Order', 2 ); -
Add channel locations
EEG = pop_chanedit(EEG, 'load',{'\GSN-HydroCel-129.sfp' 'filetype' 'autodetect'},'changefield',{132 'datachan' 0},'setref',{'1:130' 'Cz'}); -
Apply average reference
EEG = pop_reref( EEG, [],'refloc',struct('labels',{'Cz'},'Y',{0},'X',{5.4492e-16},'Z',{8.8992},'sph_theta',{0},'sph_phi',{90},'sph_radius',{8.8992},'theta',{0},'radius',{0},'type',{''},'ref',{''},'urchan',{132},'datachan',{0})); -
Create epochs of 10 seconds each
EEG = eeg_regepochs(EEG, 'recurrence', 10.0, 'rmbase', NaN);
#### Expected behavior: Epoch end (sec) to be 10
#### Actual behavior: Epoch end (sec) 0.996
#### Versions
| OS version | Windows Server 2016 Standard |
| Matlab version | 9.5.0.1033004/R2018b |
| EEGLAB version | v2020.0 |