So, I have a dataset of many points across Europe. For illustration purposes see this image below:
Each of these points has one of four categories attached to it, so the dataset I am working with has points with X and Y coordinates, and these categories are A, B, C and D.
What I would like to do then is to overlay a grid of a certain dimension over these points like here:
To then count the share of each of the points in one of the grid cells and map them out, to create four different maps for the four different categories that I have showing for each category what is the share in each of the grid cells.
So for example, if in one of the grid cells we have 10 points, 5 belong to category A and 5 to category B the share for each category in that grid cell would be 0.5. In the end, I would like to end up with four raster maps for each of the categories, where each pixel shows the share of the points of that category in that grid cell.
Illustration here:
I found similar questions like this: Counting occurence of unique points across large grid using QGIS? but usually it is just about a number of points per grid cell, whereas I need the share of points for each of the four categories. Any ideas?



