The goal is to divide a raster file into quadrants in order to make some computation in each. I'd like to split the raster and create a raster brick with those parts. I don't need to get perfect clips of the raster so the cell with data in the border of the clip could be also present in the contiguous raster brick.
I'm thinking about creating a radial grid and then extract the raster by masking it with each of the polygons within. I found these interesting questions about the topic.
How can be done this in R ?
- Note 1: number of quadrants must be a parameter.
- Note 2: raster brick must have same extension as the original raster.
- Note 3: process must be done in R (a function would be perfect)
Update 10/06/2020: I hope this schema clarifies the purpose: A Function that given a raster and a number of sectors it creates a raster brick (with number of rasters = number of sectors) where each raster keeps just the values within the correspondent sector.