ERP habituation modelling code relative to:
Mancini F, Pepe A, Bernacchia A, Di Stefano G, Mouraux A, Iannetti GD. (2018) Characterising the short-term habituation of event-related evoked potentials. eNeuro ENEURO.0014-18.2018; http://www.eneuro.org/content/early/2018/09/06/ENEURO.0014-18.2018
Written in Matlab R2016b by F Mancini, fm456@cam.ac.uk
'wilcoxon_clustercorr.m' performs a point-by-point, one-sample Wilcoxon signed-rank test of EEG waveforms is. Please see details at the beginning of the code.
The script to model the habituation of EEG data is 'svd_analysis.m'. It requires the Curve Fitting Toolbox in Matlab.
'svd_analysis' loads data from matrix 'wave_data.mat' then calls a number of sub-functions to perform the following processing steps:
- Singular value decomposition of the EEG matrix
- Estimate SVD significance
- Modelling of the right-singular vectors (habituation components)
- Compare decay models according to BIC
- Estimate p-values of winning models using resampling statistics
- Make figure of winning models for each rank and condition
- Make figures of SVD results
For more details see comments embedded in 'svd_analysis.m'
Preprocessed EEG data are available at https://osf.io/8wj3s/