Session.filter#

Session.filter(geometries, prop_name, lower=None, upper=None, **kwargs)[source]#

Filter geometries by property value range.

Automatically detects whether the property yields per-vertex arrays (point-level filtering) or scalars (population-level filtering).

Parameters:
geometrieslist of Geometry

Target geometries.

prop_namestr

Vertex property name or measure name.

lowerfloat, optional

Lower bound (inclusive).

upperfloat, optional

Upper bound (inclusive).

**kwargs

Additional parameters passed to property computation.

Returns:
tuple of (int, int, str)

(kept, removed, level) where level is "point" or "population".