I've got a number of ticket outlets, each of which has annual sales as an attribute. I'm looking to represent outlets that are near to each other (within 100m) as one single large outlet, with the sum of its composite outlets kept as an attribute. What's the best way to do this?


Here are two options, depending on what type of cluster you want.

Cluster type: Each point in a cluster is within 100m of at least one other point in the cluster.

Create a 100m buffer. Choose the option to dissolve the results.

Split multipart to singlepart. Proceed to final step (below).

Cluster type: Each point in a cluster is within 100m of all other points in the cluster.

Install the ClusterPoints plugin. Run this plugin to create clusters. It adds the new field "Cluster_ID" with a unique value for each cluster.

Use Minimum Bounding Geometry tool to create a convex hull for each cluster. The output is a polygon layer; use this for the final step.

Final step: create a field with total annual sales for the cluster:

Install the plugin refFunctions.

Using the Field Calculator, add a field with this expression:

intersecting_geom_sum( 'ticket outlets', 'annual sales' )

Substitute the actual names of your layer and attribute where it says ticket outlets and annual sales.

Use Centroids tool to convert polygons to a points.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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