[Mne_analysis] Compute source power spectral density (PSD) in a label

Alexandre Gramfort alexandre.gramfort at inria.fr
Thu Dec 26 03:27:58 EST 2019
Search archives:

        External Email - Use Caution        

hi,

you're right. This line:

plt.plot(1e3 * stc.times, stc.data.T)

is wrong. It should just be:

plt.plot(stc.times, stc.data.T)

I just fixed it:
https://github.com/mne-tools/mne-python/commit/4d92429c729fbc34ea7b5ca5e3b79845dcb9cc88

thanks
Alex

On Wed, Dec 25, 2019 at 9:46 PM Vivek Sharma <vivek.sharma1510 at gmail.com> wrote:
>
>         External Email - Use Caution
>
> Hi,
> In the following example
> (https://mne.tools/stable/auto_examples/time_frequency/plot_source_power_spectrum.html)
> why are we multiplying stc.times and stc.data.T by 1e3?
>
> Secondly, I would like to bring it to notice that in the same example the plot that is being obtained shows frequency as 10000, 20000, etc. and the unit is represented as Hz which I believe is wrong as it should be millihertz.
> I try to keep the frequency in Hz by making the following change in the code.
> plt.plot(stc.times, (1e3 * stc.data.T))
> is the change valid?
>
> --
> Vivek Sharma
> _______________________________________________
> Mne_analysis mailing list
> Mne_analysis at nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis



More information about the Mne_analysis mailing list