Mapping a set of ZIP codes - google-maps

I'm working on a delivery service that only delivers within certain ZIP codes (probably, but not necessarily, all contiguous). Given a list of ZIPs, how do I get a map on which those ZIPs' areas are highlighted or outlined?

http://www.udsmapper.org/
This should be exactly what you need.. for personal/non-commercial use only though...
If you have a list of zip codes you can even paste them into the system and they'll automatically map!
Here is their user guide too:
http://www.udsmapper.org/docs/NEW_Instructions_Creating_Service_Area_Map_10102014.pdf

Here are some links of some helpful sites:
http://benfry.com/zipdecode/
http://maps.huge.info/
http://maps.huge.info/blog/boundary_maps/
http://www.usnaviguide.com/zip.htm
I didn't spend very much time searching these sites, but it didn't look like they were sharing their databases. That's what you are going to need... A database that can give you the lat/long coordinate boundary of the zip code area. I don't believe neither Google nor Bing offer a service that does that conversion for you.
Once you are able to do that conversion, from zip code to lat/long boundary, it should be pretty straight forward in both the Bing maps control and the Google api. If you have more specific questions on the actual implementation, then just leave me a comment.

Related

Spatio-temporal visualisation with google maps

I have Call Detailed Records(CDR) data which in its raw form has timestamp, latitude and longitude. I have summarized this data to show where a user was on a particular day. What I have now are three fields: Begin(Date),End(Date) and Lat/Lon. Worth noting is that intervals are irregular and Lat/Lon can repeat. My objective is to have a visualization/animation with the following capabilities. Adjustable speed when viewing time so that I can see when a user returns to the same place. It should look something like this or this. I have searched endlessly and cant seem to find pointers to resources for use in Google maps or similar platforms. Now I have a kml file for each user but when I view it in Google Earth, the effects are not what I'm looking for. Problems include speed,its too fast and for some reason I cant control the start date of the animation. Any help will be appreciated.
CanvasLayer.js Library is what you have to integrate with your app code in order to get the sort of animated data on your Map. This library integrates Google Maps and Web GL behind the scenes and you just have to basic code for initialization and add path of your text/kml file, Rest of the things are automated.
Please follow this link to know about the code implementation and also some sample examples.
Hope this would Help!!

Stored Map Like Google Maps or OpenLayers

Is Their anything like stored maps from where I can get Latitude/Longitude from address and vice versa. Like a database file or something else other than web based services so that I will not have to be connected over Internet while calculating address from Latitude/Longitude and Counter-wise.
Thank You
EDIT : Just to be clear. We use Google API's to find out Routes between two Geo-Locations I need the Same Feature.
Nominatim ? [1] It’s one of the source for the OSM home page.
Source code is on github [2].
1: http://wiki.openstreetmap.org/wiki/Nominatim
2: https://github.com/twain47/Nominatim
EDIT: I didn’t understand correctly. You can checkout OSRM : http://project-osrm.org/
Maybe you can check out Navit it is an open source offline routing and navigation application. They have a wiki over here which also explains a bit about routing.
I have not tried the application, but one of the features mentioned in the wiki is "adress and POI search".
There are several means of contact mentioned in their wiki as well, if you want to ask them about how they did.
You might also want to check out this list to find other interesting apps that provide offline map storage, routing and/or offline address search http://wiki.openstreetmap.org/wiki/Software/Desktop
This looks interesting as well: OSM Automated Navigation Directions.

Google maps API - geocoder doesn't find 'Carson, CA'

I have a customer with store locator functionality based on Google maps API. Couple days ago the complained about locator not able to find 'Carson, CA'
Here's a really simple demo from Google itself and it doesn't work either:
http://gmaps-samples.googlecode.com/svn/trunk/geocoder/singlegeocode.html
Is there a way to contact Google support? I tried to search for any contact information but couldn't find anything useful.
It does look like a bug as there is a Carson marked on the map south of Los Angeles. It happens: geocoder data gets updated and sometimes things get missed off. Bugs need to be raised in the issue tracker. Be sure to search first (although I didn't find a previous report for this) and choose the right template when raising a new bug.
http://code.google.com/p/gmaps-api-issues/issues/list
For a store locator app, you may find searching for West Carson provides a decent start point, although this is hardly a usable workaround. Try using the zip code instead.
I don't think this is actually a bug; let me gently suggest that I think you are probably using the wrong API for looking up "Carson, CA." I'm not being harsh, just trying to help. But Geocoding has two basic functions:
Given an address as input, reply with the best Lat-Lng coordinates for that address.
Given coordinates as input, reply with the closest known address (sometimes called Reverse Geocoding).
With "Carson, CA" as input, it doesn't seem like you have given enough information to have defined an address, which probably means that the Geocoder just didn't have enough information. The same goes for the Store Locator; "Carson, CA" isn't a store.
I think what you do want to use for a search of this kind is the Google Places APIdev-guide, because you are actually looking for a place, not coordinates or an address. Using the Google Places Autocomplete, for example, you can set the tool to search for different types, for example: countries, cities, or geocode (and there are others). The first, countries will let you find places such as: Australia, Bahamas, or Canada. The second, cities, will let you find places such as: Albuquerque, Baton Rouge, or Carson, CA. The last, geocode will restrict you to address searches, which is essentially what you are using when using the Geocoder.
I made the same mistake myself the other day when I sent a request to the Geocoder that contained "Wrigley Field"; the result was some address in Georgia on "Wrigley Field Road," which had me very confused until I thought about it for awhile and then it made sense. Wrigley Field is a place, not an address. I have been working with the Autocomplete a bunch lately and that has really made the difference between the two modes of lookup clear. As a possible solution for you, if you don't provide a specific type to the Autocomplete, it will use all of them, which will allow you to find places and/or addresses. It might give you a more functional solution for your site.
Anyway, just trying to offer some helpful feedback and I hope I did help -

How to extract the lat/lng of pins in google maps?

I want to extract the latitude and longitude of a set of about 50-100 pins in a Google maps web page. I don't control the page and I don't need to do it more than once so I'm looking for something quick and dirty. I've got FireFox with FireBug as well as Chrome and all I need is something that's easier than re typing all the numbers.
Simply click the link shortcut on the map to retreive a URL for the map with pins in.
Next add &output=kml to the end of this url and use the link to retrieve a kml file containing all the pin data.
This kml file is actually in xml format so parsing it should be easy, you just need to look for <coordinates> elements which contain the latitude and longitude data you need.
The kml format is documented here: http://code.google.com/apis/kml/documentation/kmlreference.html
Just saving the .html file and using regex works:
These two reg-ex might be good starting points:
#[0-9]+\.[0-9]+,-[0-9]+.[0-9]+",geocode:"",sxti:"[-#A-Za-z .]+"
{id:"[A-Zloc0-9]+",fid
Google has change a lot the way you can extract information about google.maps and has set some limitations like numbers of queries by day.
To extract the lat and lon of Google maps you need a bit of knowledge about HMTL code and manipulating JSON/XML files. (all can be found in many tutorials.
I recommend you to extrac the data using de "Google Places API" it's VERY EASY! and you can extract about 150k locations by day for free. You have to get an account, activate your privileges of API Places (turn on/off buttom), get you secret KEY and then use a simple URL to extract the JSON/XML file. Here are two great links for that:
[1] https://developers.google.com/places/documentation/search?hl=en
[2] https://developers.google.com/places/training/basic-place-search?hl=en
If you want DETAIL info about the coordinates that you'll get, go to the section "Requesting Place Details" in the second link, that gives you info about what kind of site is that, the phone number and all the comments that users has made, if they are available.
Great coding and greetings!
Depending on the type of the map and whether the pins are set by latitude and longitude or by address, it might even work to just get the link (click on "Link" at the Google Maps page, the URL in the browser might not be the sam) and look for the "sll=[...]" parameters.

How to add ZIP Code Visualization to Google Static Maps API-generated Images?

This is related to an earlier question I asked.
The Google Static Maps API certainly seems like the way to go given the technical constraints, however, the business constraints are different and I'm starting to think there is no point where they overlap.
In short, I need to generate a map image with ZIP code boundaries, and the ZIP codes shaded in different ways to highlight some and dim others. This is obviously not something that Google has available in their API, so is there something I can do on my end to use their geocoding, their mapping, and mix in the ZIP code imagery? Without somehow building my own nation-wide tilesets to overlay the retrieved image, of course.
Something sort of like this, but without usage fees to contend with: http://maps.huge.info/zip.htm
Edit:
I've found the Cartographic Boundary Files but have no idea how to digest them into something useful.