surfplot
surfplot copied to clipboard
mismatch between Surfplot and Freeview
I have a .mgh file representing a <significance_map> in fsaverage space. I am attempting to visualize it on Surfplot:
from surfplot import Plot from neuromaps.datasets import fetch_fsaverage import nibabel as nib
left = nib.load('/lh.glmdir/FSGD_acute_vs_controls/cache.th40.pos.sig.cluster.lh.mgh')
right = nib.load('/rh.glmdir/FSGD_acute_vs_controls/cache.th40.pos.sig.cluster.rh.mgh')
fsagg=np.concatenate([left.get_fdata().flatten(),right.get_fdata().flatten()])
surfaces = fetch_fsaverage(density='164k') lh, rh = surfaces['inflated'] p = Plot(lh,rh, views=['medial', 'lateral'], flip=False, zoom=1.2) p.add_layer(fslr_agg, zero_transparent=True, as_outline=False, cbar=True, cmap='Reds') p.build()
The process runs successfully. However, upon comparing this result with the fsaverage inflated in freeview, significant differences emerge. The mapping appears in entirely different regions. What might be incorrect in the above code?
Thanks, L
Hi @pinilorenzo thank you for bringing this to my attention. Is it possible to share the files or screenshots of the differences? Or if not, are you able to recreate this issue with some mock data? I will look into this and try and recreate it locally
What version of surfplot and matplotlib are you running?
Thanks for your patience