Open mscheltienne opened 9 months ago
I can never remember what any of the stuff means and have to re-learn every time :disappointed: I would test by tweaking each one to see the effects and/or look at the code to see where each field actually gets used.
Proposed documentation enhancement
I'm struggling to debug a topographic plot, partially because I'm lacking information as to how the custom layout I provide is used by the viz functions. A layout has a
box
argument which defines the 'box' dimension(x_min, x_max, y_min, y_max)
and apos
argument which defines the unit-normalized position of the channel.. as(x, y, width, height)
, i.e. it also includes the 'box' size in the form ofwidth
andheight
.Does someone know why we have both present, I would like to include this explanation in the documentation in someform.
Next, those 'box-size' information are not even in sync. If I generate a 2D layout from an X/Y numpy array with:
I get:
The padding argument does impact
layout.box
but notlayout.pos
. What's more, plotting a topographic plot withmne.viz.plot_evoked_topo
and a custom layout using differentpad
argument has no impact.Finally, for some reason despite
generate_2d_layout
supposely normalizing thex/y
position, all the axes do not fit in the figure yielded bymne.viz.plot_evoked_topo
.Code snippet if someone wants to play with the vizualization code: (requires MNE-LSL as I was looking for a dataset with 64 channels in a 10/20 montage)
The file
pos.npy
was obtained by looking through the code ofraw.get_montage().plot(kind="topomap", sphere="eeglab")
.pos.zip
Scatter plot of the X/Y position used to generate the layout:
Topographic plot:
I will try to have a look in the coming days, if anyone has hints or ideas, they will be more than welcome :)