[GIS] How to count polygons in multipart features

qgis

I'm trying to count the number of polygons in a multipart feature. My aim is to have a 'count' attribute to quantify fragmentation of multipart land parcels.

I've looked at the field calculator and for suitable plugins, but can't see anything that would help. There are lots of ways to count points, lines and vertices, but not polygons.

Best Answer

4 years later it seems as if QGIS has integrated this feature into the field calculator. The expression syntax is:

num_geometries($geometry)

Field Calculator: num_geometries