2

I have, to start, a DEM raster and a shapefile, with random created points, within a given polygon. The DEM raster was clipped with that same polygon.

With the DEM raster, I used GRASS to perform neighborhood analysis (using "r.neighbors"), and I applied a buffer of 150m. Since the pixel size is 30x30m, the size I used was 5 (and I did not select the "circular neighborhood" option).

Then, I uploaded the new raster to QGIS, to perform DEM Terrain models analyses (Raster > Analysis > DEM (Terrain Models)). In "Mode" option, I used: Slope, TRI and Roughness.

My final objective is to atribute the value of "Slope", "TRI" and "Roughness" to each point of the shapefile. However, after creating "Slope", "TRI" and "Roughness", a kind of buffer (if it can be called this way) appeared surrounding the limits of the area, as you can see here: enter image description here

The problem is, that buffer has an extremely high value that is not representative of the area, and some points fall into that buffer, so I obtain erroneous "Slope", "TRI" and "Roughness" values.

Do you have any idea of a solution for this problem?

2
  • Why not use GRASS GIS for all ?
    – gene
    Commented Jun 16, 2016 at 18:42
  • I didn't look in GRASS for the other tools, I only used it because there was no way to perform neighborhood analysis in QGIS. But I'll look for the other tools in GRASS!
    – mto23
    Commented Jun 16, 2016 at 22:13

1 Answer 1

1

I think the solution to what you call "buffer" is to create a MASK raster in GRASS. Then the r.neighbors analysis (and all other raster analyses) will be limited to the area covered by the mask. You would do that in GRASS by converting the polygon to a raster, and naming it MASK:

v.to.rast input=<your polygon> output=MASK use=value

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.