We are trying to implement cluster map based on telephone dialing codes. need your help in implementing.
How to create maps and how to map the volume against the corresponding area and how to show the volume numbers in the corresponding area in the graph?
Your help is appreciated.
What have you tried so far?
I am not sure where to start. All i have is telephone area codes. Do i need to have a lookup created with telephone area codes with latitude and longitude? To proceed further?
Yes, you will need a means to convert area codes into coordinates. A lookup table should work well. Depending on your data, you would then use the
geostats command to plot it on a map.
@klchandrakanth, is this dialing code lookup required only for US or anywhere in World?
I have created a sample lookup table with telephone area code, state,lat and long.
with below command i am able to see the coordinates.
| inputlookup DDDLookupSample.csv | geostats count by DDD_Code latfield=Latitude longfield=Longitude
However, not able to map my query result to the map. Any help is appreciated.
my base query that is giving the count of the area codes with below.
source="log-ura" | eval PhoneDDD = substr(PhNumber,1,2) | stats count by PhoneDDD
My CSV is like this.
DDD_Code States Latitude Longitude
11 Sao Paulo -23.65283405 -46.52781661
68 Acre -9.070003236 -68.66997929
82 Alagoas -9.48000405 -35.83996769
96 Amapa -0.039598369 -51.17998743
92 Amazonas -3.289580873 -60.6199797
For US and for Canada, it looks like there are ESRI files (or similar) available for that from at least a couple of places.
You may have another issue, though. Area codes are no longer geographically distinct; most of them in the most populous locations are overlays, so you may have three different area codes that represent identical geography. You need to identify what the purpose of your map is before you decide on representation.
I suspect that you probably should go with plotting all overlays to the exact same coordinates, and aggregating the results as a single pie chart. Presumably, if you are presenting a geographical representation, then you are trying to see where your calls are coming from.
Check your underlying data and see if your assumptions are correct or if there is a more specific field, though. I make calls from my Dallas 469 number while I am on site in Florida or Kansas or San Jose.