var shape = {"title":"Washington Heights","description":"NYC Neighborhood","tags":"","points":[[40.841509000000002, -73.935714000000004], [40.840308, -73.935156000000006], [40.839171, -73.935027000000005], [40.838099999999997, -73.936314999999993], [40.834366000000003, -73.937944999999999], [40.833067, -73.939362000000003], [40.831767999999997, -73.940392000000003], [40.830502000000003, -73.940177000000006], [40.834398, -73.949060000000003], [40.836995999999999, -73.948330999999996], [40.838586999999997, -73.946742999999998], [40.841118999999999, -73.944597000000002], [40.84469, -73.943825000000004], [40.85154, -73.940562999999997], [40.855825000000003, -73.939233000000002], [40.868515000000002, -73.930864], [40.865561999999997, -73.927131000000003], [40.859167999999997, -73.922838999999996]],"author":"AhmedF"};
var map = new GMap2(document.getElementById("map"));
map.setCenter(new GLatLng(40.849509, -73.93595),5);
map.addControl(new GSmallMapControl());
var latlngs = [];
for (var i=0; i<shape.points.length; i++)
{
    latlngs[i] = new GLatLng(shape.points[i][0], shape.points[i][1]);
}
var poly = new GPolygon(latlngs, '#ff0000', 3, .8, '#ff0000', .4);
map.addOverlay(poly);
var bounds = poly.getBounds();
map.setZoom(map.getBoundsZoomLevel(bounds));
map.panTo(bounds.getCenter());