3

I know that there are many similar topics around and I think I have checked them all but they all refer to different settings or aims.

My case is simple: I have

  • polygons: building_blocks
  • points: buildings (with a field called "type" indicating one of nine classes [basic, bungalow, villa, hall...])

I want to create pie charts from the building blocks indicating the fraction of the contained building types. Accordingly, I need the number of each of the nine building types as a separate column in the output polygon feature table.

Building blocks and building types

The structure as I would need it (as table of the polygons, with BT= number of each building type) Example for an output attribute table

I have tried the following tools:

  • Spatial Join: Calculates the sum of points, but without distinguishing by "type"
  • Aggregate Points: Has a Summary Fields option, but it doesn't group by "type"
  • Count Overlapping Features: Has no group option

I know that it could be done with multiple steps:

  1. select all points with building type 1
  2. run aggregate
  3. join the tables and add a new column for type 1
  4. repeat with building types 2-9

But it is for a cartography course and I'm sure that this could be done easier (with two or three steps at least instead of 9)

Am I missing something crucial here?

I am using ArcGIS Pro 2.9.3 as a GIS Professional Advanced user.

2 Answers 2

6

You can achieve the table structure you require in 3 steps and then you can join that back to your polygon dataset.

So below is your starting scenario:

Data

Step 1 - Join block ID to points. In ArcGIS Pro 3.0 you could use the new Add Spatial Join but the spatial join works just as well. So you are joining polygons to points thus the end result is a new layer where each point is tagged with its block ID.

Step 2 - Summarize your data as shown below.

Tool

This creates this output, it has all the information you require just not structured as you need.

Stats

Step 3 - Reorganize your table using the pivot tool, this is setup as shown below:

Pivot

This creates this output:

Results

Step 4 - Join this table to your polygon data and symbolize your pie charts.

0
3

Your first step should be to join the block IDs to the building points using Identity or Intersect. Then, you can run Frequency or Summary Statistics on the output using block ID and building type as the frequency/case fields to get a table whose rows will look like block ID | building type | number of buildings. (Rows will only be created for combinations of block ID and building type where at least one building exists.)

This table's format is not quite what you're looking for, so I would probably use the Pivot Table tool that @Hornbydd mentioned.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.