Plot_topomap of averaged evoked

Dear MNE users,

Currently, I am using evoked.plot_topomap to plot topo map of EEG.

evoked.plot_topomap(0.1,ch_type=‘eeg’, time_unit=‘s’)

if i use this command, I can get topomap at 0.1s. I would like to get averaged topomap of evoked (I need only one topo map averaged over time). Do you know the method?

Best,
Kyu

Hey @kyuwanchoi you should look into the average parameter of the plot_topomap method: mne.Evoked — MNE 1.7.0.dev15+gb107d92ec documentation

it says:

The time window around a given time to be used for averaging (seconds). For example, 0.01 would translate into window that starts 5 ms before and ends 5 ms after a given time point. Defaults to None, which means no averaging.

so you can probably tweak it to fit your usecase.

Alternatively you could get the data from your evoked object, average it over the time dimension using np.mean, and then create a new evoked object using that data. See the documentation on how to create an evoked object from an array here: Creating MNE-Python data structures from scratch — MNE 1.7.0.dev15+gb107d92ec documentation

Your new evoked object will then just have one timepoint.