I have a shapefile of 4 phyla (4 polygons for each class). Each contains multiple species ranges inside it. This means I have data for almost 200 species in these 4 polygon. My data look like this (figure attached below). I get this data from IUCN and clip it for my study region. Link of data is https://www.iucnredlist.org/resources/spatial-data-download
I want to calculate the species richness for each grid cell of (1km by 1km) after rasterizing them in
How do I get the total species in each grid cell like the figure attached below?
If combined richness is not possible, single like reptiles richness can also work for me and so on. I want to do analysis in R.
I attached the link from where I download the data. Geometry of Polygons ar Multipolygons. These 4 polygons contain data of 200 species (81 for reptiles, 104 for mammals and remaining 15 for other 2 phylum. So 81 column for reptiles species and so on (attribute table of only one phylum (reptile) is attached below to understand data type).
I am new on R and I don't know how to even load the polygon file in R.