As mentioned, symbology expressions allow you to create symbology categories or ranges based on a function, equation, or data logic. So, how do you do that? Well, one of the common ways is to use if statements.
if statements are used to create conditional logic. That means the statements make use of operators, such as equal to, not equal to, greater than, or less than, to group data. For example, if you wanted to symbolize parcels based on land value by identifying them as having a high, medium, or low value per acre, you might create an expression that looks like this:
var value = ($feature['Parcel_Polygon.par_val']
/$feature['Parcel_Polygon.Acre'])
if (value <= 10000){
return 'Low Value';}
if (value > 10000 && value <= 50000){
return 'Medium Value';}
else {
return 'High Value';}
The first line in this expression defines a variable...