nipy / PySurfer

Cortical neuroimaging visualization in Python
https://pysurfer.github.io/
BSD 3-Clause "New" or "Revised" License
240 stars 97 forks source link

brain is in ms when stc is in seconds #147

Closed matt-erhart closed 7 years ago

matt-erhart commented 8 years ago

I'm trying to save a movie of an stc in with tmin etc and times in seconds but when I create a brain object it is converted to ms in ...data_dict['lh']['time']. Is this a bug or is there some conversion I need to do?

mwaskom commented 8 years ago

Please provide the exact code you are using. It is hard to say what you need to do if all the information we have is "with tmin etc".

matt-erhart commented 8 years ago

Sure thing, let me know if you need to know more.

   group_avg_stc = sum([i[0] for i in subj_stcs]) / len([i[0] for i in subj_stcs])
    brain = group_avg_stc.plot(subject='fsaverage',hemi='split',
                  subjects_dir=fs_dir,views=['lat', 'med'],
                  config_opts=dict(width=2500, height=1400),
          colormap='jet')

group_avg_stc.tmin and tstep are in seconds. group_avg_stc.times is in seconds. brain.data_dict['lh']['time'] is in ms.

christianbrodbeck commented 7 years ago

This inconsistency was recognized, and was solved by introducing the time_unit parameter in mne (see mne docs) so I think this issue can be closed.