# evoked.plot\_topomap help

**URL:** <https://mne.discourse.group/t/evoked-plot-topomap-help/1702>\
**Category:** Mailing List Archive (read-only)\
**Tags:** list-archive\
**Created:** [January 8, 2019, 11:23am UTC](https://mne.discourse.group/t/evoked-plot-topomap-help/1702 "2019-01-08T11:23:56Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/free1/uploads/mne/original/1X/85cc6bd2b69cb698a166dc6d880fb550510d0144.jpeg) [@system](https://mne.discourse.group/u/system)\
**Post date:** [January 8, 2019, 11:23am UTC](https://mne.discourse.group/t/evoked-plot-topomap-help/1702/1 "2019-01-08T11:23:56Z")

</div>

External Email - Use Caution

Hello everyone;

I am trying to use the topomap plot, but I am having some issues (script below)

I guess the problem is that I am trying to load the sensor location from the initial fif file but then using it as montage info on a .mat file epochs loaded.

the error I get is:

ValueError: Cannot determine location of MEG/EOG/ECG channels using digitization points.

Any help?

import os.path as op  
import numpy as np  
import pandas as pd  
import matplotlib.pyplot as plt  
from [scipy.io](http://scipy.io) import loadmat  
import mne

data\_path = op.join("exocos", "MEG", "sample", "s1")

fif = data\_path + '/run01\_sss.fif'  
tmin = -.500

Montage = mne.channels.read\_dig\_montage(fif=fif)  
print(Montage) #here everything looks good

info = mne.create\_info(102, sfreq=500, ch\_types='mag', montage=Montage)  
print(info) #here I want to select only 102 MAG channel from the list of 339 sensors in the fif file

epochs\_S\_D\_I = mne.EpochsArray(S\_cueD\_targetI\_Suj1\_rej['trial'], info=info, tmin=tmin, baseline=baseline) #here is where I am switching to the .mat structure where I have my epochs

#Compute the evoked response  
evoked = epochs\_S\_D\_I.average()  
evoked.plot(time\_unit='s') #this plot function works fine

evoked.plot\_topomap(ch\_type='mag', time\_unit='s') #this does not

-------------- next part --------------  
An HTML attachment was scrubbed...  
URL: [http://mail.nmr.mgh.harvard.edu/pipermail/mne\_analysis/attachments/20190108/97b23c93/attachment-0001.html](http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20190108/97b23c93/attachment-0001.html)

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/free1/uploads/mne/original/1X/85cc6bd2b69cb698a166dc6d880fb550510d0144.jpeg) [@system](https://mne.discourse.group/u/system)\
**Post date:** [January 9, 2019, 6:11pm UTC](https://mne.discourse.group/t/evoked-plot-topomap-help/1702/2 "2019-01-09T18:11:51Z")

</div>

External Email - Use Caution

hi Alfredo,

it's possibly a bug or at least a limitation of the create\_info when  
you say "mag".

can you share a snippet that illustrates the problem using the sample data?

btw why don't you have already the montage in your MEG fif file? it's weird  
that you need to load it from a different file.

Alex
