I'm trying to plot a Drilldown using SAS VA 7.2 using "Geo Region Map" object. I'm able to plot the State but unable to plot the city.
-> state(geography) with property (subdivision names)
For city whatever i tried it went in vain.
Attached is my sample data.
SAS Visual Analytics has predefined geographic information for countries and states, but not for cities.
If you add the latitude and longitude coordinates for the cities to your data set, then you could plot the cities by defining a custom geographic role within VA.
The documentation for that task can be found here:
I hope this helps,
I believe that is the way, but ideally you would obtain a table with the city names and coordinates, and then import and merge that table into your data.
Base SAS 9.4 ships with the mapsgfk.World_cities dataset which contains the longitude and latitude for 3,200 cities in India (and many others worldwide). This is a huge dataset, so you would likely want to subset it before importing and merging it.
There also many free sources and paid sources online for city coordinates.
Actually, MAPSGFK. WORLD_CITIES is in SAS/Graph. And if you have MAPSGFK, then you have Proc GEOCODE which will let you give it a list (data set) of cities that you want and getting the lat/longs back for those cities (using MAPSGFK.WORLD_CITIES). You can just use the cities in WORLD_CITIES with ID="IN" (India) and get a list of the Name of the city and the Lat/Long. But using Proc Geocode will let you make sure your list of city names is spelled the same as the MAPSGFK list.
That is a good addition, Darrell. World city lookup was added to GEOCODE after the time when I supported it.
The PROC GEOCODE documentation can be found here:
It has a helpful example program showing world city lookup.
@balraj Hi Balraj! I saw the data that you have uploaded of Indian states and in there you have Dadra and Nagar Haveli. I am just curious to know were you able to map Dadra and Nagar Haveli. I am trying the same and for me Dadra and Nagar Haveli goes unmapped. Please let me know if you are able to map it. Many Thanks!
Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.
If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website.
See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.
Find more tutorials on the SAS Users YouTube channel.