mne-tools/mne-python — pull request #333 by dengemann (2012-12-27 18:04:58+00:00)
Title: WIP + ENH: define higher order events

Hi all,

this one is related to #133 -- @Eric89GXL and @christianmbrodbeck, listen ;-) --- agains smartness for events. It's a refactored version of a gist I posted on #133 on evaluating button presses.
This one goes beyond that, it allows you to filter / create new events based on the lag between the events. I wrote an example in which fast button presses (within 700 ms) to the smiley face are selected.
I also returns an array of lags you can use for more accurate behavioral analyses or as parametric regressor.
The important difference to my previous gist is that this one is much simple and does only operate on event arrays instead of raw data.

- define_events function for creating new events via time lag between exisiting events
- example: plot fast motor responses

Tell me what you think. The example might be improved, also the function and agument names can be discussed. I hope I can convey the point though.