Increase a map of paths with d3.js

0

I'm creating a map of a state using D3.js o The code picks up the data from a GeoJson file to show the map of the screen but with a very small size. I do not use the .scale () and .translate ([]) functions to change the size of the map. the Geojson file follow this link the code is below.

             test                           

</head>
<body>

    <script>

       var canvas = d3.select("body").append("svg").style("background-color","#ccc")
            .attr("width", 700)
            .attr("height", 700)


        d3.json("geojs-15-mun.json",function(data){

           var group = canvas.selectAll("g")
                   .data(data.features)
                   .enter()
                   .append("g")

           var projection = d3.geo.mercator();

           var path = d3.geo.path().projection(projection);

           var areas = group.append("path")
                   .attr("d",path)
                   .attr("class","area")
                   .attr("fill","steelblue");




        });


    </script>

</body>

    
asked by anonymous 22.09.2017 / 04:57

0 answers