Select to view content in your preferred language

Spatial Analyst - Overlapping Ploygon Raster

5587
4
07-06-2010 10:50 PM
NickBauer
Deactivated User
Hi,

Thanks in advance for any suggestions.

I have a polygon layer with features that intentionally overlap (records of events over many years).

I want to be able to create a raster grid that sums the number of polygons (events) have occurred for that particular area or grid cell (say 100m x 100m). 

I have found similar articles in other forum threads but none seem to do exactly what I'm after.

I'm using ArcInfo 9.3 with Spatial Analyst.

Thanks,

Nick
0 Kudos
4 Replies
ModyBuchbinder
Esri Regular Contributor
Hey Nick

I had the exact problem lately, I can tell you what I did but I cannot send code.
I found out that the best way is to use vector and not raster.
I used "Create Fishnet" to create a layer that divide the area to boxes.
Then used "Feature to Polygon" to make a polygon layer out of it.
Then used "Add Field" to add a count field.
Then I run a loop in ArcObjects, selecting all box polygons (Contain or intersect) under each overlap polygon and add one to their count field.
It took 30 seconds for 15 polygons but I think at least half of it is the creating of the first layer so 30 polygons should be 50% more.
Trying to rastrize  and sum rasters took close to 4 minutes for the same area with the same resolution (and you need an extension too).

Have Fun
Mody
0 Kudos
GregWise
New Contributor
Hi Nick,
We've done something similar, but without using rasters.
First, add an integer item called COUNT to your polygon feature.
Then use the Intersect tool to intersect your polygon layer on itself.
Then use the Dissolve tool, and add the COUNT item as the Statistics field and set the Statistics Type to SUM.
This should output a polygon layer with the number of overlapping features captured in the COUNT field.
I hope this helps,

Greg Wise
Department of Planning and Local Government
South Australia
0 Kudos
CaseyBentz
Frequent Contributor
I would like to expand on Greg's answer.  I used his method successfully, but think some added detail might help some others.  Here are my steps.

  1. I created a file geodatabase and imported the feature class from SDE

  2. I added the field count

    1. Type Short Integer

  3. I calculated the field with the value of 1

  4. I ran the intersect tool adding the same polygon feature class twice

  5. I then ran the delete identical tool

    1. For the fields parameter I used Shape and the FID of the original feature

    2. I did this because I found the same polygon was duplicated in my overlap areas, but not outside my overlap areas


    3. I then ran the Multipart to Singlepart tool on the output of the intersect

      1. After the intersect, I appeared to have multipart features


      2. I then ran the Dissolve tool using shape_area and shape_length as  my dissolve fields

        1. I used the count field as the statistics field with sum as the statistic type


        2. This gave me an accurate count of overlapping polygons

        3. For my use, I ran the polygon to raster tool to use in further analysis

        4. Hi Nick,
          We've done something similar, but without using rasters.
          First, add an integer item called COUNT to your polygon feature.
          Then use the Intersect tool to intersect your polygon layer on itself.
          Then use the Dissolve tool, and add the COUNT item as the Statistics field and set the Statistics Type to SUM.
          This should output a polygon layer with the number of overlapping features captured in the COUNT field.
          I hope this helps,

          Greg Wise
          Department of Planning and Local Government
          South Australia
          0 Kudos
          SimonLiu
          Deactivated User
          If you have all the overlapping polygons in a single feature class, this GP model will create a new polygon feature class showing the overlapping areas and how many polygons intersect at each one. The output features can then be turned into a raster if needed.

          http://www.arcgis.com/home/item.html?id=1dd4a6832b3d40b494dbf8521cc5134c

          The technique behind the model is described here:

          http://blogs.esri.com/esri/arcgis/2012/11/13/spaghetti_and_meatballs/

          ArcInfo (10.0 or before) / Advanced (10.1) is required because it uses the Feature To Polygon tool.
          0 Kudos