Select to view content in your preferred language

Group region on float raster

287
1
Jump to solution
02-14-2024 08:17 AM
Anne-MarieDubois
Regular Contributor

Hello everyone,

Is there a way to use the equivalent of the Group region tool but for float raster? (ERROR 000969) I don't want to interger, I want to calculate region based on float value.

 

Kind regards,

 

 

 

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
DanPatterson
MVP Esteemed Contributor

There is no such tool, but a method could be employed with its own limitations.

If you want to retain some of the decimal precision for some reason, scale up the float raster by a factor of 10, take its integer value, perform the regiongroup.  You can always scale back the resultant zones by dividing by the factor used in the first step.  For example

a = regiongroup(int(raster * 10))

b = a/10

 


... sort of retired...

View solution in original post

0 Kudos
1 Reply
DanPatterson
MVP Esteemed Contributor

There is no such tool, but a method could be employed with its own limitations.

If you want to retain some of the decimal precision for some reason, scale up the float raster by a factor of 10, take its integer value, perform the regiongroup.  You can always scale back the resultant zones by dividing by the factor used in the first step.  For example

a = regiongroup(int(raster * 10))

b = a/10

 


... sort of retired...
0 Kudos