[GRASS-user] GRASS GIS 7.8.5 r.water.outlet

Kelsey Wong kelsey.wong at shaw.ca
Mon May 24 15:38:27 PDT 2021


Hi Micha and Stefan,

Thank you for you suggestions! I was able to extract the attributes into a list, and use the r.water.outlet to create the watersheds.

I now have a number of different maps in grass, each with one record representing a different watershed. I was wondering if there was a grass module that would compile each record/watershed from each map into a singular map with each watershed having one record? I’ve tried v.patch but it seems to merge all of the watersheds into one record in the final output map.

Thanks,

Kelsey

> On May 19, 2021, at 12:24 PM, Stefan Blumentrath <Stefan.Blumentrath at nina.no> wrote:
> 
> Hi Kelesy,
> 
> In addition to Michas very good suggestions you can try the table module in pygrass: https://grass.osgeo.org/grass78/manuals/libpython/pygrass.vector.html?highlight=table#module-pygrass.vector.table
> Or the db_select module from the scripting library: https://grass.osgeo.org/grass78/manuals/libpython/script.html?highlight=select#script.db.db_select for all kind of tables
> Or the vector_db_select module: https://grass.osgeo.org/grass78/manuals/libpython/script.html?highlight=select#script.vector.vector_db_select for tables connected to vector maps
> To get the coordinates in Python...
> 
> Cheers
> Stefan
> 
> -----Original Message-----
> From: grass-user <grass-user-bounces at lists.osgeo.org> On Behalf Of Kelsey Wong
> Sent: onsdag 19. mai 2021 20:52
> To: grass-user at lists.osgeo.org
> Subject: [GRASS-user] GRASS GIS 7.8.5 r.water.outlet
> 
> Hi,
> 
> I am trying to use the r.water.outlet function in a python script in GRASS. For the 'coordinates' parameter my x,y coordinate values are stored in two columns in the attribute table of another layer. Is there a way to access these values from the attribute table directly?
> 
> Thanks,
> 
> Kelsey
> _______________________________________________
> grass-user mailing list
> grass-user at lists.osgeo.org
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.osgeo.org%2Fmailman%2Flistinfo%2Fgrass-user&data=04%7C01%7C%7Cd2729cbc538a4733864908d91af73bb6%7C6cef373021314901831055b3abf02c73%7C0%7C0%7C637570471438665050%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=OrVazRa4Mkas0DxUkYtb8i0lfHwFul06zoYFzxO0Dhs%3D&reserved=0



More information about the grass-user mailing list