Dear M/EEG users,
I found a serious bug in spm_eeg_convert and spm_eeg_epochs that has
been there since the beginning of SPM8. There is a piece of code that
excludes trials whose boundaries are outside the the data file. Such
trials appear when there are triggers of interest very close to the
beginning or to the end of the recording. The bug was that the
condition labels were not updated when it happened. This could cause
the entire set of condition labels to shift thus completely scrambling
the condition label assignment. The problem could be serious when:
1) There were more than one different conditions defined during
epoching/conversion.
2) There were trials that were excluded at the beginning of the recording.
Excluded trials at the end of the recording do not cause a problem. In
the case of conversion the problem only occurs when epoching is done
during conversion based on events (so 'just read' is OK).
Surprisingly none of SPM M/EEG users has come across this bug until
now. I can only explain it by the fact that usually people start the
recording slightly before they start their stimulation sequence so the
cases when the initial trials in a recording are out of bounds are
rare. But if you think you could possibly be affected, I'd recommend
you to put the attached fixes in your SPM folder and re-do your
analysis starting with the epoching step.
The fix will be included in future SPM updates. I'm very sorry for the
inconvenience.
Best,
Vladimir
|