sccn / viewprops

EEGLAB plugin with improved pop_prop and more
5 stars 1 forks source link

Spherical coordformat dipoles are plotted incorrectly #5

Open jiversen opened 2 years ago

jiversen commented 2 years ago

Spherical coordinate dipoles were not plotted correctly on the dipplot panels, e.g. faces_4.set

the call to dipplot currently uses hardcoded 'MNI' coordformat

Instead, take coordformat from EEG.dipfit.coordformat

jiversen commented 2 years ago

Insert after line 404 of pop_plot_extended.m

% recover coordformat from EEG.dipfit
            coordformat = EEG.dipfit.coordformat;
            if isempty(coordformat)
                coordformat = 'MNI';
            end

change the call to dipplot to use coordformat variable

  ```

dipplot(EEG.dipfit.model(chanorcomp), ... 'meshdata', meshdatapath, ... 'mri', mripath, ... 'normlen', 'on', 'coordformat', coordformat, 'axistight', 'on', 'gui', 'off', 'view', [0 0 1], 'pointout', 'on');