pyavs.plot_median_erf

pyavs.plot_median_erf(epochs: mne.Epochs, event_type: str | None = None, ch_type: str = 'mag', times: float | List[float] | None = None, title: str | None = None, show: bool = True, **kwargs) Figure[source]

Plot median ERF (Event-Related Field) for MEG sensor space data.

This function computes the median across epochs and creates a joint plot showing both the time series and topographic maps.

Parameters:
  • epochs (mne.Epochs) – The epochs data to plot

  • event_type (str, optional) – Type of event to plot (if None, uses all epochs)

  • ch_type (str, optional) – Channel type to plot (‘mag’, ‘grad’, or ‘meg’) (default: ‘mag’)

  • times (float, list of float, or None) – Time points for topographic maps. If None, uses peak times

  • title (str, optional) – Title for the plot

  • show (bool, optional) – Whether to show the plot (default: True)

  • **kwargs – Additional arguments passed to plot_joint

Returns:

fig – The figure object

Return type:

matplotlib.figure.Figure