coffeine.spatial_filters.ProjSPoCSpace#
- class coffeine.spatial_filters.ProjSPoCSpace(shrink: float = 0.0, scale: float = 1.0, n_compo: int | str = 'full', reg: float = 1e-15)#
Project SPD matrix subspace given by SPoC.
Computes Source Power Co-Modulation SPoC presented in [1].
Note
This implementation is absed on MNE-Python. Contrary to the PyRiemann implementation, this implementation use the arithmetic mean across the covariances as a reference.
- Parameters:
- n_compoint
The size of the subspace to project onto.
- random_statefloat | np.random.RandomState
The random state.
- shrinkfloat
The shrinkage factor, like alpha in scikit-learn shrunk_covariance.
- scalefloat | ‘auto’
Optional normalization that can be applied to the covariance. If float, the value is directly used as a scaling factor. If auto, scaling is obtained by 1 devided by the average of the trace across covariances.
- regfloat (defaults to 1e-15)
A regularization factor applied in subspace by reg * identity matrix. The number is chose to be small and numerically stabilizing, assuming EEG input scaled in volts. This is sensitive to the scale of the input and may be different for MEG or other data types. Please check.
References
[1]Dähne, S., Meinecke, F.C., Haufe, S., Höhne, J., Tangermann, M., Müller, K.R. and Nikulin, V.V., 2014. SPoC: a novel framework for relating the amplitude of neuronal oscillations to behaviorally relevant parameters. NeuroImage, 86, pp.111-122.