For modeling purposes, I need to use two raster maps that contain exactly the same number of rows and columns. How should I process my maps to obtain this result? For now, my maps don't have the same number of rows and columns...
1 Answers
Supposing that they are aligned with the same resolution (cell size), in QGIS you can do that with this approach. For example, I have these 2 raster maps where it is obvious that I should clip the big one by the small map:
First, open layer properties of the "small" map and copy its extent in a text editor (see next image, red rectangle). Modify the order 1, 2, 3, 4, without commas, to 1, 4, 3, 2 and copy it.
Close layer properties and open Clipper Tool in Raster -> Extraction -> Clipper. Select the names of input and output files, and drag with the mouse one arbitrary area on the map and click on the icon pencil for editing gdal_translate command. Change projwin parameters for the modified at text editor.
After OK, the clipped image it will have the same number of rows and columns if they have the same resolution.
- 29,891
- 4
- 41
- 80
-
Do you know how to work this around in R? http://gis.stackexchange.com/questions/231165/same-extent-and-resolution-of-rasters-but-different-number-of-cells – Vijay Ramesh Mar 09 '17 at 18:28



