I am trying to preform a spatial join between two vector files where i have one polygon-grid and a classified vector-file, as shown below:
I would like to be able to classify my grid according to the majority class in each cell, so if it is mostly red etc. Similar to zonal statistics or rasterstats but for vectordata.
I tried using GeoPandas's
but the result is clearly not based on majority of each class. I have tried using different switches in
sjoin but without any luck.