BookmarkSubscribeRSS Feed

Customizing a web map visualization in a SAS Visual Analytics report with #WebMapWednesday

Started ‎05-29-2019 by
Modified ‎05-29-2019 by
Views 1,212

In this article, we'll begin to expand on the web map we successfully integrated into the SAS Visual Analytics Report in the previous article. We left off with a simple choropleth, but there is much more that can be done with different options applied to a web map.


Web map customization

While it is definitely worthwhile to have a basic choropleth overlaid onto an interactive map, it does not allow for much more information being delivered to a user. In particular, our data regarding the agricultural fields in Lower Puna, Hawaii has some more information that would be great to be able to represent visually. Each field has a different category of crop which can right now only be seen in a tooltip when clicking on a choropleth polygon.


A good solution to this would be to use the color category option available to web maps. With this option, every choropleth polygon can be colored according to the type of crop that is present.


Adding a color category is very simple now that we laid the groundwork in previous articles. Simply add this to the end of the URL you are using in the data-driven content control we created last article:




Your web map should now look similar to this:


Screen Shot 2019-03-29 at 12.28.26 PM.png


Now each choropleth polygon is colored according to the type of the crop it holds. To access the legend and see which color corresponds to what crop, click the question mark icon in the bottom right corner.


Screen Shot 2019-03-29 at 12.31.16 PM.png


You’ll notice the web map is beginning to look a bit busy with all the different information being presented. This would be a good opportunity to turn off some of the layers that the lava flow feature service provided.


Click on the menu icon in the top right corner of the web map to get a list of all the present layers.


Screen Shot 2019-03-29 at 1.14.22 PM.png


It’s most likely that the layer containing the shapes for the agricultural baseline is named “objectid”. This isn’t the most descriptive label so before we turn off some of the lava flow layers, let’s rename the layer with our agricultural baseline data. Add the following to the end of the URL you are using in the data-driven content control:


&title=Agricultural Baseline


The name of the layer should now be changed to “Agricultural Baseline” in the layer list.


Screen Shot 2019-04-12 at 12.44.28 PM.png


Next to each layer in the list there is an eye that controls the visibility of a layer. Try toggling the “Agricultural Baseline” layer by clicking on the eye icon next to it.


In order to clean up some of the features from the lava flow feature service, click the dropdown arrow next to the eye for the “Lava Flows” layer. The feature service includes several layers related to the volcanic activity of the Lower Puna area. We really only need the layer from the most recent lava flow; so toggle off all the features except for “Flows 5/3 – 8/9.” Your map should now look like this:


Screen Shot 2019-03-29 at 1.25.29 PM.png


The color option on web maps has another use beyond applying color categories. Let’s think about the additional data we have available for the agriculture data. There should be a measure role in the data set you added called acrage.


Screen Shot 2019-03-29 at 1.30.27 PM.png


It may be useful to have each polygon colored according to field acreage.. This can be accomplished with the color option as well. Simply replace the addition to the end of our URL for the data-driven content from the color category set up with this:




Your web map should now look like this:


Screen Shot 2019-03-29 at 1.36.22 PM.png


Just as we did after setting the color category, click on the question mark icon in the bottom right corner to bring up the legend for the web map.


Screen Shot 2019-03-29 at 1.41.52 PM.png


The legend shows the color and value range representation of the acreage for each agricultural field. If the default colors used for the range are not to your liking, it is possible to customize the colors associated with the max and minimum values in a range. Let’s say we would prefer to use a green color for our color range. Add this to the end of your URL:


&colorMin= 4C5E15&colorMax= CDFF39


Your map should now look like this:


Screen Shot 2019-03-29 at 1.58.27 PM.png


Now you can see that we have a darker green representing the fields with lower acreage and a lighter green representing higher acreage. You can specify any hex colors for the color minimum and max of a color range. Colors can also be expressed with the rgba(#, #, #, #) format.


Now say we want to adjust the range of the color response so that the max value is closer to the middle of the range. We could accomplish this using a tool provided by Esri called smart legends. To enable smart legends, add this to the end of your url:




Your map should now have a second question mark in the bottom right corner. Click on the question mark to the left so that the smart legend controls appear.


Screen Shot 2019-03-29 at 2.07.14 PM.png


Now you can easily adjust the numeric range of the color response for the web map.


Web map customizations allow for more ways to present information that can add more life to your visualizations.  The options covered in this article are standard across all the visualization types, but more will be covered in future #WebMapWednesday articles. In the next post, we will be looking at the last two visualization types available for web map integration, along with the options that can be applied to them.


Additional resources


Next Post


In the next #WebMapWednesday post, we will build our first visualization with a web map.WWWPic.jpg


Remember to follow the #WebMapWednesday article series on the SAS Communities Library and the associated Twitter hashtag. Comment below or Tweet your questions and comments!


Data Appendix

  • ArcGIS Server Service provided by the US Geological Survey. The feature layer used in the report visualizes the lava flow from May 3, 2018, until August 9, 2018.
  • Agricultural Baseline data was collected by the Spatial Data Analysis and Visualization Lab at the University of Hawaii at Hilo. 
Version history
Last update:
‎05-29-2019 10:22 AM
Updated by:


Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.


Register now!

Free course: Data Literacy Essentials

Data Literacy is for all, even absolute beginners. Jump on board with this free e-learning  and boost your career prospects.

Get Started

Article Labels
Article Tags