bbci / bbci_public

MATLAB toolbox for Brain-Computer Interfacing (BCI)
MIT License
152 stars 104 forks source link

What is TIMEEPS? #213

Closed damo-da closed 5 years ago

damo-da commented 6 years ago

It seems that the sole purpose of TIMEEPS used in proc_segmentation.m L#108 is to increment a frame. I am unable to understand why.

BenjaminBlankertz commented 5 years ago

Hi underscoredam, for some reason, I didn't receive notifications about issues for several months, and so I also missed your question. I am sorry about that. Unfortunately, I don't remember the reason exactly. In the straight forward implementation, numerical errors could lead to an unexpected shift in the extracted segments, when the sampling interval (1000/cnt.fs) was fractional. Introducing the TIMEEPS code, this shift is avoided. For integer sampling intervals it should not make a difference. Best regards, Benjamin