# Is it possible to construct a topological map of road network of Bangalore?

I saw this example wherein the CityData gives the map of a city.

But this is available for a relatively small set of curated regions.

Is it possible to extract such map, say the topologically connected roadmap (with edges representing edgelengths) of an arbitrary city?

-
Mma can read GIS shapefiles via Import. If you have access to these files (and many larger cities have GIS departments that make this information publicly available) then you should be able to use it. –  bobthechemist Sep 16 '13 at 13:04

I found some free gis data of indian roads. I extracted the india-latest.shp.zip and then imported the roads.shp file. Here is a quick example to extract relevant roads:

(* Make sure to fix the path *)
(* This just happens to be where the Lines are located in the data,
see below for some tips to explore the list  *)

(* Where's bangalore? *)
bangaloreCenter = {77.56, 12.97};

(* Takes a line and returns True if within 1 lat/long unit of bangalore center,
note that this is a shady test for the sake of this example *)
inBangaloreQ[l_Line] := Sqrt[#.#]<1 &[
Nearest[l[[1]], bangaloreCenter][[1]] - bangaloreCenter]

(* Extract all roads passing through bangalore *)

Beware that this is a ton of data, so don't let the front-end print everything out. When exploring the structure of indiaRoadData don't be shy with Dimensions, //Short and Head/@...