mne.viz.plot_filter

mne.viz.plot_filter(h, sfreq, freq=None, gain=None, title=None, color=’#1f77b4’, flim=None, fscale=’log’, alim=(-60, 10), show=True)[source]

Plot properties of a filter.

Parameters:

h : dict or ndarray

An IIR dict or 1D ndarray of coefficients (for FIR filter).

sfreq : float

Sample rate of the data (Hz).

freq : array-like or None

The ideal response frequencies to plot (must be in ascending order). If None (default), do not plot the ideal response.

gain : array-like or None

The ideal response gains to plot. If None (default), do not plot the ideal response.

title : str | None

The title to use. If None (default), deteremine the title based on the type of the system.

color : color object

The color to use (default ‘#1f77b4’).

flim : tuple or None

If not None, the x-axis frequency limits (Hz) to use. If None, freq will be used. If None (default) and freq is None, (0.1, sfreq / 2.) will be used.

fscale : str

Frequency scaling to use, can be “log” (default) or “linear”.

alim : tuple

The y-axis amplitude limits (dB) to use (default: (-60, 10)).

show : bool

Show figure if True (default).

Returns:

fig : matplotlib.figure.Figure

The figure containing the plots.

Notes

New in version 0.14.

Examples using mne.viz.plot_filter