Select to view content in your preferred language

counting points in an area

3039
1
Jump to solution
07-16-2014 08:54 AM
AbbyParish
Deactivated User

Good morning,

I was hoping to get some help with a problem I am working on. I have two shapefiles, a point file that includes a column for group, and a polygon shapefile. I need to figure out A) how many points are in each polygon and B) how many of each group are in each polygon (for example area A has three points in group 1, four points in group 2, and zero points in group 3)

I was able to solve problem A with no problems, I simply did a join which added the count column to the new polygon shapefile. I am having problems trying to figure out how I am suppose to solve problem B. Does anyone have any suggestion as to how I can go about doing this?

The end goal is a spreadsheet with the area name, the total count of points in that area, and the count of points for each group in that area.

I am using ArcGIS 10.2 for Desktop and I have the basic license.

0 Kudos
1 Solution

Accepted Solutions
DavidJenkins
Regular Contributor

Abby,

Your question is pretty simple to execute.  What you want to do is a spatial join.  In this case you can join points to polys to get the counts but lose the groups or... you can join the polygons to points and the result with be another point file but with the attributes of the polygons that the point fell within.  From there, it's just an exercise in summarizing the results in your join output table.

To get you started, add both classes to ArcMap.  In the table of contents, right-click the point layer and select 'Joins and Relates' --> Join...

Change the drop-down at the top of the dialog box from 'Join attributes from a table' TO 'Join data from another layer based on spatial location'

Select your polygon layer in the drop-down under number 1 and be sure that the radio button below is selected for 'it falls inside.'

Give your output a file name and location and run it.

The result will be added to ArcMap.  Open the table and summarize on your Polygon ID and / or group or whatever...  If you find summaries in ArcMap limiting, I suggest exporting the table out as a csv and open it in Excel.  You can now use the Pivot function to get all the answers you need.

Hope this helps!

View solution in original post

1 Reply
DavidJenkins
Regular Contributor

Abby,

Your question is pretty simple to execute.  What you want to do is a spatial join.  In this case you can join points to polys to get the counts but lose the groups or... you can join the polygons to points and the result with be another point file but with the attributes of the polygons that the point fell within.  From there, it's just an exercise in summarizing the results in your join output table.

To get you started, add both classes to ArcMap.  In the table of contents, right-click the point layer and select 'Joins and Relates' --> Join...

Change the drop-down at the top of the dialog box from 'Join attributes from a table' TO 'Join data from another layer based on spatial location'

Select your polygon layer in the drop-down under number 1 and be sure that the radio button below is selected for 'it falls inside.'

Give your output a file name and location and run it.

The result will be added to ArcMap.  Open the table and summarize on your Polygon ID and / or group or whatever...  If you find summaries in ArcMap limiting, I suggest exporting the table out as a csv and open it in Excel.  You can now use the Pivot function to get all the answers you need.

Hope this helps!