Skip to main content
100%

Activity 8 Country

✓ Published0🌍 Public
Mmn0658
Last edited Jul 19, 2023
Created on Jul 19, 2023
Forked from Activity 8 Country

This example displays a map of India rendered as an SVG path, centered and scaled using a Mercator projection. The code loads world country boundaries from the World Atlas TopoJSON dataset via `d3.json`, extracts India’s geometry with `topojson.feature`, and fits it to a 960×500 viewport using `d3.geoMercator().fitSize`. A single path drawn with `d3.geoPath` visualizes the country’s outline. The visualization demonstrates loading external JSON, filtering TopoJSON features, and projecting geographic data entirely with D3 v5.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes