Hi !
I have multiple PSG recordings from all different patients and I want to compute the PSD per subject but also averaged over all the subjects.
I’m able to extract the psd per subject with
spectrum = epochs.compute_psd(method = 'welch',fmin=2.0, fmax=40.0, n_fft = int(2*epochs.info['sfreq']), n_overlap= int(epochs.info['sfreq']/2))`
psds, freqs = spectrum.get_data(return_freqs=True)
and then I would concatenate the psds of the subjects together and then take the mean of that concatenated np array such that I get an average psd for all my subjects.
But what I still don’t understand is the following:
- What is the unit of the Power Spectral Density? Moreover, I’ve seen that sometimes the logarithmic scale has been applied to the resulting psds - is there a standard way to handle and visualize the power spectrum?
- When computing the PSD plot, e.g. for just one subject, I would do the following:
spectrum.plot( average=True)
which averages over the channels, but what about the epochs? Do I have to average over the epochs as well? - Do the chosen parameter values for
n_fft
andn_overlap
seem reasonable to you?
Cheers,
Annina
- MNE version: 1.5.1
- operating system: Windows 11