atlas_view_remove_small

atlas_view_remove_small(atlas, min_area, views=None)

Remove region geometries below a minimum area threshold.

Context geometries (labels not in core) are never removed. Useful for cleaning up small polygon fragments from 2D projections.

Parameters

Name Type Description Default
atlas BrainAtlas Brain atlas object. required
min_area float Minimum polygon area to keep. required
views str | list[str] | None Optional view name(s) to scope the removal. If None, applies to all views. None

Returns

Name Type Description
BrainAtlas Modified atlas copy.