This site uses cookies

By using this site, you consent to our use of cookies. You can view our terms and conditions for more information.

Workshop: Detecting Single-Trial Cognitive Events in EEG Using Hidden Semi-Markov Pattern Analysis and the HMP Python Package

In this workshop, participants will learn how to use hidden semi-Markov pattern analysis (HMP, Anderson, Zhang, Borst, \& Walsh, 2016) to detect cognitive stages on a by-trial basis in EEG data. HMP combines hidden semi-Markov models with multivariate pattern analysis to quantify the number of cognitive processes within a trial as well as estimate their durations on a single-trial basis. The workshop is decomposed into lectures about the method and tutorials. Tutorials will be based on a python implementation with new functionalities (see and will guide participants through all the possibilities offered by HMP. After this workshop, participants will be familiar with the method and the code, able to simulate data corresponding to their research question, fit HMP models to their data, analyse the resulting models and draw inferences on experimental and individual differences, and leverage their EEG analysis through by-trial estimates of cognitive events timing. The last lecture will allow participants to further think about how they can integrate HMP with cognitive and statistical models of behaviour. To make the most of the workshop you should bring your laptop with Anaconda installed (see [anaconda]( for how to install). Once conda is installed you can already download MNE python ( to save some time during the set-up, a recommended way is to use a dedicated conda environment as follows (see [conda managing environments]( ``` $ conda create --override-channels --channel=conda-forge --name=hmp mne ``` Please don't yet install the hsmm_mvpy package (, instructions will be given during the workshop.
Detecting single-trial cognitive events in EEG using hidden semi-Markov pattern analysis and the HMP python package
Dr. Jelmer Borst
Leendert Van Maanen
Dr. Gabriel Weindel