I'm working on some EEG data we collected using the Emotiv Epoc headset using 14 channel sensors.
I need to isolate chunks of data where all 14 channels are stable (non-noisy) for a given length of time (e.g. 5 seconds). I've written a MATLAB script for this, such that I calculate the standard deviation of each channel and pass an analysis window over the data, comparing the difference between maximum and minimum values in the window to this standard deviation (i.e. where maximum - minimum is less than the standard deviation [or 3-5 standard deviations], I treat that window as stable).
Based on this criteria, I am having some success in finding 5 second long segments but am worried this data may not be reliable (or not as stable/artefact free as desired).
Are there any better ways of performing this analysis? Even better, are there any functions built into EEGLAB for this very purpose?
I've selected only the relevant channels and can now look through my EEG data files.
I am no neuroscience expert, actually I'm rather new to this sort of analysis, so apologies if this question is overly basic or off-point.
We collected our data in a museum environment (very noisy in many ways), with participants sitting as still as possible for 2-minute sessions at a go. For this reason, there is a high likelihood of artefacts being found in the data due to movement, the environment and possibly even inaccuracies from the device itself (since we went through a rather large number of participants, cleaning and charging the headsets in between trials).
From what I've discussed with the team, I've been told that removing artefacts wouldn't solve the issue (though admittedly I'm no expert as to why this would be).
For clarity, the data we've collected looks similar to the plot below.
And we're looking for a minimum of 5 seconds of stable data, closer to the plot below.
Also, I know this data selection can be done manually using pop_eegplot, however since we have close to 300 data files I'm looking to automate this (and hopefully get more reliable selections).