2

I have a Landsat raster time-series (2000-2016) of 102 rasters for the same location. Since the original Landsat scenes don't overlap exactly, I defined a polygon to use for cropping all the rasters to the same extent, since I need to stack them.

I work in R and used this function to batch process my time-series:

processLandsatBatch(x=listzip, pattern=glob2rx('*.zip'), outdir=output_gz, srdir=srdir, delete=TRUE, vi='ndmi', mask='fmask', keep=0, e= Riau_sp, overwrite=TRUE)

Riau_sp is my extent polygon.

However in the output I see that the rasters still don't have exactly the same extent, and I get ERROR when I try to stack them. Here is an example of two of my rasters extent after processing:

extent: 101.6222, 102.8827, -0.6339126, 0.6637299 (xmin, xmax, ymin, ymax)

extent: 101.6222, 102.8827, -0.6339154, 0.6637271 (xmin, xmax, ymin, ymax)

The y-values are just a bit off, even though both were cropped with the same extent-polygon.

Any idea what has happened, and how I may fix it?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.