Jump to content

Select and process random subsets of raster DEM


Recommended Posts

Dear all,

I have been attempting to do this for several days without any result.

I have a raster DEM (in a WGS84 coordinate system) and I would like to extract random square subsets (of a chosen size) of this raster for processing.

What I have done so far is generate a set of random points within the raster extent, create circular buffers around those points and convert these buffers into square buffers using the Feature to Envelope tool. I then use ArcPy to bath clip the raster based on the square polygon features - ultimately generating a number of clipped rasters that is equal to the number of random points I started with.

The problem I am running into is that I would like to perform calculations (mean, standard deviation etc. of cell values) within each raster, but I need these calculations to be comparable so that I can make comparisons between say mean values across rasters. My though process was that for this to be valid, I need the same number of cells in each raster subset.

However, the initial raster I am sampling from spans -7 to -37 deg of latitude, and therefore the buffers I generate have shapes that vary as a function of latitude (they are geodesic buffers, so those buffers close to the equator are approx. circular, whereas those away from the equator are more distorted). The same applies to the dimensions of the cells of the initial raster DEM.

I am getting confused about what I need to do to obtain comparable raster subsets in terms of the cells they contain? Do I need to project my layers to an appropriate projected coordinate system and work from there? Or do I need to adapt the width/radius of the buffers to the position of the points I am applying them to (so as to end up with an equal number of cells in each raster subset)?

Many thanks for any suggestions or ideas,

Phil

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.

Disable-Adblock.png

 

If you enjoy our contents, support us by Disable ads Blocker or add GIS-area to your ads blocker whitelist