Cluster extension threshold

Dear all, ist there a nilearn function to remove clusters smaller than a given number of voxels from a t-map? It seems to be a simple thing but I cannot find it since days. I mean something simple like the extent threshold in SPM.
Kind regards

Hello !

In next release you will have a function map_threshold with this kind of argument. For now you can import it from nistats.thresholding (or nilearn.stats if you use nilearn master)

For an example on how to use it : https://nistats.github.io/auto_examples/03_second_level_models/plot_thresholding.html#sphx-glr-auto-examples-03-second-level-models-plot-thresholding-py

2 Likes