[GRASS-dev] module for collecting percentages of raster classes in a vector map

Veronica Andreo veroandreo at gmail.com
Mon Jul 2 17:40:02 PDT 2018


El lun., 2 jul. 2018 13:21, Moritz Lennert <mlennert at club.worldonline.be>
escribió:

> Hi everyone,
>
> I have a vague memory that someone has coded this before, but cannot
> find it anywhere, but before I code it myself I wanted to know if my
> vague memory actually was right: I need a module that takes a
> qualitative raster map (e.g. land cover map) and a vector polygon map
> and calculates the share of each raster class in each vector polygon.
> This just means looping of the raster categories, create a reclass map
> for each category (category = 1 and rest=null) and then use r.univar to
> calculate non_null_cells/(non_null_cells+null_cells), so it's fairly
> easy to code, but even so, does anyone know if something like this
> already exists, before I reinvent the wheel ?
>

This would be super nice to have ;)

Vero
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-dev/attachments/20180702/66075f6f/attachment.html>


More information about the grass-dev mailing list