Select to view content in your preferred language

Unique Values Unused ( Count = 0 ) in Symbology Layer Files (.lyr) – Sorting/Filter Option

1961
3
01-13-2015 12:33 PM
Status: Open
Labels (1)
SarahWillett
Regular Contributor

If a feature class is clipped to a specific AOI (area of interest) and we utilize the original layer file (.lyr) to represent the newly clipped polygons (in this instance) there will be unused symbols displayed in the classification of the unique values and in the final legend (see screen capture below).

0EME0000000HHi6

The current solution is to manually select one by one (or alt select) to remove the unused classifications/symbology.


Would like to see ESRI add a simple sort ascending or descending tool to the “Count” column to easily sort out all the unused symoblogy. In this instance it was easy to select the 22 geological classifications and manually remove them. Yet, there are instances with other data sets that may contain100+ unique values that need to be manipulated and cleaned before final representation in a legend.

3 Comments
RichardFairhurst
An arcpy mapping solution would be much more powerful and let you make these adjustments without destroying the value order that often takes hundreds of mouse clicks to establish.  If the UniqueValuesSymbology methods could borrow symbols from an existing layer file rather than just destroy the symbols when I revise its value list, I could write a script to strip out unused values from the layer in seconds without destroying the value symbols or value order.  I cannot support anything that destroys the value order without the addition of a Move to Top and Move to Bottom button for reordering the fields and arcpy mapping methods that make establishing and maintaining symbols and value order together much easier.
EoinTyrrell

Would love to know if there's any update on this. I'm using a national layer file with 100's of values for a smaller area. I want to add descriptions and having all the unused layer values in such a pain. 

RichardHowe

I would agree that this option would be great. Just in case it's of use to anybody here then please see my explanation at the bottom of the thread linked below for achieving unique values when matching from an existing layer file. Certainly for the examples cited above then I think it will save you some time!

Managing Symbology using Python


Important bit copied and pasted below:

Therefore, the workaround is to manually create a layer file (hopefully you only need to do this once), from scratch, with all of your symbols and labels as you would like them as a "Unique Values" list (you can speed this lengthy process up by loading your style file into your Style Manager). Save it and then reference that using the "apply symbology from layer" command.