Focal or Neighborhood CountIF

614
0
01-23-2014 07:09 AM
Benjaminswanson
New Contributor
I am trying to find a script or work flow to count the number of cells in a 3x3 neighborhood that are greater than the center cell of the neighborhood.  The hope is that it would do this using each cell (excepting borders) as the center cell, and then move on to the next, and that it would write the count value in a new raster file.  This would be much like the neighborhood statistics tool in spatial analyst but instead of calculating a mean, maximum, stdev, etc, it would be returning a countif.

There used to be a VB script that did this for AG8.  If someone can help me get it, or something similar, working for 10.1 that would be great.  I'm guessing its already out there, I just haven't found it.

Thanks!!
0 Kudos
0 Replies