Visualize polygons as points for symbology on the fly

1940
9
05-18-2023 05:57 AM
Status: Open
Tiff
by
Frequent Contributor

I would like to be able to symbolize a polygon as a point using its centroid, for example, in a web map. This is especially helpful if you want a zoomed out view for your map to start and have it transition into polygons as you zoom closer. This seems like a small but very helpful visualization option for many use cases.

9 Comments
DataOfficer

We have a somewhat hacky workaround for this.
Firstly ensure there is some sort of numeric field in your attribute table. In our case, we give all features a value of 1 in this field.

Then, in the symbology (assuming using Map Viewer), choose the attributes to symbolise by. In our case, we have a categorical field (text) and our numeric field mentioned above, called Point.
Then, pick the Types and Size style. Open the style options.

Under Types, set up the styling for your categorical field (if you have one). This will be the symbology when you are zoomed in to the polygon.

Under Count and Amounts (size), choose a symbol style, and set the size range to be the same for all values (unless you want it to vary). For example, we set our points to all be 20px. Zoomed out, we see the points, and zoomed in, we see the polygon with the point in the centre.

Tiff
by

Hi @DataOfficer, this is helpful - thanks! I've implemented this for a couple maps already.

I am having issues with all the points showing up and I only have 25 features within an entire county. Depending on my zoom level, I only see some and not others, even if I reduce the point size to make sure they don't overlap. It looks like it is just dynamically changing based on the zoom extent. This makes it a problem for when you are not seeing the full distribution of these features when some points are somehow not showing up at that zoom extent. Have you experienced this, or have any suggestions for me?

CarolineLindhe

Would be very helpful if the same option as for extent indicator symbol option in ArcGIS Pro exist for polygons in Map Viewer.

DebSF
by

@Tiff I'm having the same issue as you, with only some of the points showing when zoomed out. Did you ever figure out a way round this?

Tiff
by

Hi @DebSF unfortunately I don't think so! I think we just accepted that we would see everything once zoomed in (and the polygons show).

DataOfficer

I think the only alternative currently available would be to have two copies of the same layer, one visualised as points with a set zoom level, and the other showing the polygons at a closer zoom level.

CarolineLindhe

I got a workaround from Esri Sweden that works well for us!

1. Open Format Polygon Symbol for your polygon layer and choose Properties and Structure (wrench icon).

CarolineLindhe_3-1755755306726.png

 

2. Delete Fill Symbol Layer (you should still have a Stroke layer).

CarolineLindhe_2-1755755294710.png

 

3.Add Marker layer from Add symbol layer. 

CarolineLindhe_1-1755755281397.png

 

CarolineLindhe_0-1755755261527.png

 

4.Go to Layers and pick a symbol for your Marker, choose color, outline and size of your choice.

CarolineLindhe_4-1755755322209.png

 

5. Under Marker Placement and Placement choose At center.

CarolineLindhe_5-1755755340732.png

 

6. If you have polygons in your map they will appear with a dot. If you zoom in you can also see how the polygon outline appears.

CarolineLindhe_6-1755755364866.png

 

CarolineLindhe_7-1755755395811.png

 

 

Tiff
by

Hi @CarolineLindhe, thank you for the detailed post! It looks like you are configuring this in Pro then publishing. To not require overwriting, is there a similar workaround you've found in configuring the points on the fly in AGOL?

CarolineLindhe

You can publish the symbol to a Portal at least, don't know if you can to AGOL. But if you can you can change symbol to this one in AGOL.

The instruction is quickly translated from Swedish, I hope it makes sense.

Log in as Portaladmin to your Portal and add a 2D Web Style library to your Portal.

 

Prepare your symbol in ArcGIS Pro on a random polygon layer. Make sure the layer's name is the name you would like for your symbol in the Portal. Save your .aprx.

Note: You need separate projects for points, lines and polygons.

Note: Give points an outline to make sure there is an option to change the outline colour in the Portal. 

 

 

 

 

 

Make sure you are logged in to the right Portal as Publisher

 

Save you symbol as a style item by chosing Style Items on the ribbon menu Share.

CarolineLindhe_0-1755781529066.png

 

On the ribbon meny Share choose Web Style and you newly created Style.

CarolineLindhe_1-1755781640513.png

 

 

In Share As Web Style give the item a Name, Summary, Tags. Choose 2D as Style Type and choose where you want to publish it to Share with your organization and the group  Web Styles. Analyze and Share

 

Logga in i portalen som Publisher and make sure everything works.