I would like to add the average, minimum and maximum value of, let’s say soil moisture (variable "value" in my case), to each NUTS3 region (= a NUTS3 region is a polygon of a certain small area in Europe).
However, soil moisture values are stored in little grids. Therefore, I need to find a way to calculate which grids overlap with a certain NUTS3 region in order to determine the average soil moisture value for that NUTS3 region. Visually, it can be compared to this picture where little grids approximate together the shape of US states: http://fieldguide.mt.gov/RangeMaps\ESMapQUAD_9217.jpg
It is possible that one NUTS3 region consists of 2 full grid cells and 3 half grid cells, while another NUTS3 region consists of only a 0.75 grid. It is also possible that some grids are empty because I don’t have values there.
My raster and NUTS shapefile can be found through the following link: https://drive.google.com/folderview...FtRGtSdEl1c1NvY205TGpack9xSFc2T2s&usp=sharing
<ul>library(rgdal)
grid
However, soil moisture values are stored in little grids. Therefore, I need to find a way to calculate which grids overlap with a certain NUTS3 region in order to determine the average soil moisture value for that NUTS3 region. Visually, it can be compared to this picture where little grids approximate together the shape of US states: http://fieldguide.mt.gov/RangeMaps\ESMapQUAD_9217.jpg
It is possible that one NUTS3 region consists of 2 full grid cells and 3 half grid cells, while another NUTS3 region consists of only a 0.75 grid. It is also possible that some grids are empty because I don’t have values there.
My raster and NUTS shapefile can be found through the following link: https://drive.google.com/folderview...FtRGtSdEl1c1NvY205TGpack9xSFc2T2s&usp=sharing
<ul>library(rgdal)
grid