mne.viz.plot_raw_psd

mne.viz.plot_raw_psd(raw, tmin=0.0, tmax=inf, fmin=0, fmax=inf, proj=False, n_fft=2048, picks=None, ax=None, color='black', area_mode='std', area_alpha=0.33, n_overlap=0, dB=True, show=True, n_jobs=1, verbose=None)

Plot the power spectral density across channels

Parameters:

raw : instance of io.Raw

The raw instance to use.

tmin : float

Start time for calculations.

tmax : float

End time for calculations.

fmin : float

Start frequency to consider.

fmax : float

End frequency to consider.

proj : bool

Apply projection.

n_fft : int

Number of points to use in Welch FFT calculations.

picks : array-like of int | None

List of channels to use. Cannot be None if ax is supplied. If both picks and ax are None, separate subplots will be created for each standard channel type (mag, grad, and eeg).

ax : instance of matplotlib Axes | None

Axes to plot into. If None, axes will be created.

color : str | tuple

A matplotlib-compatible color to use.

area_mode : str | None

Mode for plotting area. If ‘std’, the mean +/- 1 STD (across channels) will be plotted. If ‘range’, the min and max (across channels) will be plotted. Bad channels will be excluded from these calculations. If None, no area will be plotted.

area_alpha : float

Alpha for the area.

n_overlap : int

The number of points of overlap between blocks. The default value is 0 (no overlap).

dB : bool

If True, transform data to decibels.

show : bool

Show figure if True.

n_jobs : int

Number of jobs to run in parallel.

verbose : bool, str, int, or None

If not None, override default verbose level (see mne.verbose).

Returns:

fig : instance of matplotlib figure

Figure with frequency spectra of the data channels.