You could convert the raster layer to a vector layer. In the attribute
table you'll have a column with the raster value (the watershed values) and
the cat column, which gives you the unique identifier for each polygon.
Next you just convert the vector back to raster using the cat column as
raster value.

But depending on your data, you might also want to check out r.clump or
r.clump2 (I think the latter is a add-on).

Paulo


On Fri, Jul 5, 2013 at 11:03 PM, Stephen Sefick <sas0...@auburn.edu> wrote:

> I have a raster map with watersheds that are the same value.  Is there an
> easy way to reclass the map with every distinc basin to have a unique value?
>
> many thanks,
>
>
> --
> Stephen Sefick
> ****************************************************
> Auburn University
> Biological Sciences
> 331 Funchess Hall
> Auburn, Alabama
> 36849
> ****************************************************
> sas0...@auburn.edu
> http://www.auburn.edu/~sas0025
> ****************************************************
>
> Let's not spend our time and resources thinking about things that are so
> little or so large that all they really do for us is puff us up and make us
> feel like gods.  We are mammals, and have not exhausted the annoying little
> problems of being mammals.
>
>                                 -K. Mullis
>
> "A big computer, a complex algorithm and a long time does not equal
> science."
>
>                               -Robert Gentleman
>
> ______________________________**_________________
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/**mailman/listinfo/grass-user<http://lists.osgeo.org/mailman/listinfo/grass-user>
>
_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

Reply via email to