Ultimately I would like to automate the process of generating clusters from points (representing buildings and amenities within a neighbourhood), and placing points at street intersections which are nearest the centres of the clusters. The data would imported from OSM, which represent buildings, amenities and other desired data. I am not sure which workflow is best, of QGIS, FME, or with Python (or a combination of).
The simplified workflow would be as follows;
- Importing data from OSM, which are points representing buildings and amenities in a neighbourhood
- Creating a grid overlaying the points.
- Counting the points in each section of the grid
- Slightly move the grid, first in the x then y direction
- Repeat step 3 and 4 (similar idea to a for loop in Python); this is to catch "stray points", or to verify the existence of clusters.
- Over the series of loops, determine which sections of the grid have the greatest number of points
- Place points at street intersections nearest the centre of clusters with greatest weight.
Another thing I would like to implement is an option to toggle OSM tags to be included in the points, such as amenity or tourism, but I'm not sure how to implement that as well.
So far I have been using mostly FME (and QGIS to generate shape boundary of the neighbourhood to test). My current issues are that I am not sure how to implement a looping system and counting system, as well as isolating each section in a grid. I have used NeighborhoodAggregator, but I am struggling a bit with counting points in each section of a grid, and I find that there is no way to move the grid around, and I don't know if it's possible to do a for loop.
If there is a better set of components to use in FME, or if this task is better suited to either QGIS or with Python, then I would be interested to know.
I am new to spatial analysis, and I have used FME because I have heard it is good for cleaning data regarding spatial analysis. The reason I ask is that while I have started this project using FME, I have noticed questions regarding automation being asked in the context of QGIS.