I have two rasters and a study area vector, they are all WGS84 CRS. When I use the vector to mask those rasters, the results showed different extents and rows and columns. I tried 'extract by mask' in R(terra::mask),ArcGIS Pro, QGIS, ArcMap.

I summarized the results(rows and columns) in this table.

enter image description here

I don't know how to upload test data on StackExchange. But the rasterA(2017) and rasterB(2018) are from the same datasets ——"http://data.tpdc.ac.cn/zh-hans/data/faae7605-a0f2-4d18-b28f-5cee413766a2/"

But there is a tiny difference. The result extent of 2018,2019,2020 are different with 2017 and before.

  • I guess different implementations behave differently with pixels that are partially masked. Without test data it is hard to say anything about the difference between A and B with the same software. Do rasterA and rasterB have the same pixel size and origin?
    – user30184
    Mar 26, 2022 at 19:08
  • I don't know how to upload test data on this. But the rasterA and rasterB are from the same datasets "data.tpdc.ac.cn/zh-hans/data/…"
    – jackywang
    Mar 27, 2022 at 6:44


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.