SEDF Class Breaks by Size

537
1
04-18-2019 05:55 AM
BenjaminSperry1
Occasional Contributor

I would like to produce a map like this:

I have a spatially enabled data frame with a column with numeric values (integers). I want vary the size of the symbol by value. I have found documentation for changing colors, which works fine, but I can't figure out how to change size.

Here is my current code:

red_rel.spatial.plot(map_widget= m3,
                     renderer_type = 'c',
                     method='esriClassifyNaturalBreaks',
                     class_count=20,
                     col='MARK_Red')

I imagine it is a matter of changing the 'c' in renderer_type to something else but I haven't figured out what that is. There should also be a way to set a size range.

Many Thanks.

also, is there a way to clear the symbology so each time I run the script it doesn't just overwrite the previous symbology?

ArcGIS API for Python v. 1.6

Jupyter Lab v. 0.35.4

0 Kudos
1 Reply
andrei_ste
New Contributor III

Hi Benjamin,

I had the same issue and I managed to solve it with a simple renderer and a size variable defined in the visual_variables property. date_zi is my spatially enabled dataframe: solution.pngMore information related to the size variable you can find  here: https://developers.arcgis.com/documentation/glossary/size-variable

Although the examples provided in the following link are for the Javascript API for ArcGIS, they work also for the Python API since they are both built upon the ArcGIS REST API. The difference is that for the Python API you need each key to be written between commas: https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-visualVariables-SizeVar...

0 Kudos