Data export from Specparam

Hi,

For my research I want to do anlysis on the aperiodic part of the spectrogram for which I used specparam model. I now want to do further analysis on the aperiodic part of the spectrogram in matlab. When I export the specparam to matlab, I do not get the same output as shown in the tutorial for specparam/Fooof.

Can someone explain to me how I can extract all the values of the aperiodic part from brainstorm to matlab so I can do further analysis there?

Be sure that you are looking at the right fields in the struct that is the EXPORTED_VARIABLE:

FOOOF parameters are stored in EXPORTED_VARIABLE.Options.FOOOF

If you want to reconstruct the aperiodic part of the spectrum.

  1. You can do it your self with the provided parameters:

Check this post (and the thread) for details and code to do so:

  1. You can export the aperiodic only in Brainstorm as spectrum file, so instead of the original PSD, it will have the aperiodic spectrum. This is described in the ** Convert FOOOF model parameters to regular PSD files** section:
    https://neuroimage.usc.edu/brainstorm/Tutorials/Fooof#Convert_FOOOF_model_parameters_to_regular_PSD_files

Export to Matlab the resulting file specparam: x/yms Power | aperiodic, as the aperiodic spectrum will be in the field TF with the shape [nChannels, 1, nFreqs].