macro_eeg_model.evaluation.fooof_tester#
Classes#
A class responsible for testing the presence of peaks in EEG power spectra using FOOOF. |
Module Contents#
- class macro_eeg_model.evaluation.fooof_tester.FooofTester(frequencies)[source]#
A class responsible for testing the presence of peaks in EEG power spectra using FOOOF.
- frequencies#
The array of frequencies corresponding to the power spectrum.
- Type:
numpy.ndarray
- fm#
The FOOOF object for fitting spectral models.
- Type:
FOOOF
- __init__(frequencies)[source]#
Initializes the FooofTester class using FOOOF.
- frequenciesnumpy.ndarray
The array of frequencies corresponding to the power spectrum.
- get_peaks_positions(powers)[source]#
Extracts the peak positions from the power spectrum using FOOOF.
- Parameters:
powers (numpy.ndarray) – The power spectrum from which to extract peaks.
- Returns:
A binary array indicating the presence of peaks at the specified frequencies. 1 if a peak is present at a given frequency, 0 otherwise.
- Return type:
numpy.ndarray