[GRASS-user] Divide raster map using vector line

Helmut Kudrnovsky hellik at web.de
Tue Jun 6 22:44:24 PDT 2017


Rich Shepard wrote
> Running 7.3.svn here on Slackware-14.1/-14.2 and looking at both vector
> and raster modules I don't see how to overlay a vector map on a raster map
> to divide the raster into two sections.
> 
>    The raster map has the same value in every cell. I want to change the
> value in cells north of a vector map of a road. If there's a workflow
> description in the docs please point me to it. Otherwise, please suggest a
> procedure to accomplish this.
> 
> TIA,
> 
> Rich
> 
> _______________________________________________
> grass-user mailing list

> grass-user at .osgeo

> https://lists.osgeo.org/mailman/listinfo/grass-user

What about?:

-g.region by your raster 
-v.in.region to get a vector area of your raster 
-split the vector area by your road
-Add a new attribute column and give 1 for the area which shouldn't change
and the other the number which you want to divide 
-v.to.rast by attribute 
-r.mapcalc with some if statement 





-----
best regards
Helmut
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Divide-raster-map-using-vector-line-tp5323270p5323289.html
Sent from the Grass - Users mailing list archive at Nabble.com.


More information about the grass-user mailing list