I'm new to QGIS and stuck with this task. Here's the data I'm working with:
- 1-square-kilometer grid Shapefile of Germany (https://www.zensus2011.de/SharedDocs/Downloads/DE/Shapefile/Inspire.zip?__blob=publicationFile&v=5)
- Population Data for each kilometer-grid as CSV. Can be joined with the grid Shapefile with column "ID_1km". Column "Einwohner" represents population divided in 7 classes (-1 unknown, 0 to 6 with 6 being the highest population density) (https://www.zensus2011.de/SharedDocs/Downloads/DE/Pressemitteilung/DemografischeGrunddaten/csv_Zensusatlas_klassierte_Werte_1km_Gitter.zip?__blob=publicationFile&v=8)
- Germany's counties "Kreise" as Shapefile (VG250_Kreise.shp)(https://www.zensus2011.de/SharedDocs/Downloads/DE/Shapefile/VG250_1Jan2011_WGS84.zip?__blob=publicationFile&v=29)
The goal is to calculate the weighted population centroid for each county (image 1) based on the population density grid (image 2). In the end I want to export a list of the latitude/longitude coordinates of the centroids of all counties.
So far I was able to join the CSV data with the 1km-grid Shapefile. Then I've tried intersecting the two layers and playing around with the vector centroid function but nothing has worked. I have no clue how I can tackle this task and I couldn't find any solution online.