Questions tagged [feature-count]

Display number of features of a layer in QGIS

Filter by
Sorted by
Tagged with
6
votes
4answers
1k views

Fill with @row_number based on group field in QGIS 3

Is there a way to fill the table with a row number so that count will restart as new group (identified by a separate column) starts? As a result, "row number" column will restart the count ...
6
votes
2answers
234 views

Adding consecutive unique ID starting from 1 for each distinct set of values

I need to add a unique "ID" (using $ID or @row_number) but the problem is that I need to start from 1 to "...n" considering identical values from other field, then, when there is a different value, ...
7
votes
1answer
1k views

Counting number of features within another feature using aggregating function in field calculator of QGIS?

My data: 1 polygon layer + 1 point layer My target: Calculate the number of points and the sum of a field within each polygon using the aggregate function in the QGIS field calculator. I know I can ...
4
votes
1answer
194 views

Get number of changed features in a layer under edit mode using pyqgis

Is there a method I can find out, how many features in a layer have changed during edit mode (including changes in the attribute and the geometry)?
1
vote
2answers
96 views

Count features in layers and categories

I want to automatically count features in my opened layers, and add the result in the layer name, with pyqgis. I can do it with this code : layers = QgsProject.instance().mapLayers().values() for ...