I have a grid full of hexagons that I am trying to bin points. However, instead of using the Vector > Analysis Tools > Points in Polygon which counts the number of point inside each hexagon, I'm trying to sum up the values of other attributes for each hexagon. Better yet, it would be great if I could do this as well as count the points inside each hexagon.

For example, my datatset is formatted like this:

ID  Lat  Long  Score
1  43.1 -431.5 .75
2  44.3 -431.6 .89
3  40.8 -429.7 .12
4  100.1  80.9 .36
5  99.8   76.1 .65
6  91.2   75.9 .24

What I'm hoping will be something like this:

Hexagon Sum   N
  1     1.76  3
  2     1.25  3

2 Answers 2


After alot of trial and error, I found my answer. For GIS beginners, like myself, what I was looking for was a spatial join, which could be done easily with QGIS:

Vector > Data Management Tools > Join Attributes by Location


Vector > Data Management Tools > Join Attributes by Location

--> Does a join on the DB which multiplies the number of rows of the two layers for the selected attributes. So this would create a polygon for every point (one-to-many relationship). Taking your example a layer of 12 polygons each with a different Score value would be created. This is not what you asked for and will blow up your layer without leading to quick result. This is not what you want.

What you want to do is using the "Join attributes by location (summary)" tool in the Processing Toolbox and calculate the "count" as summary:

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.