This repo is deprecated. See a new version here.
This repository provides a convenient redistribution of the Ecuador cartographic boundary shapefiles, 2015 edition as vector data.
To align the names of subnational jurisdictions in Ecuador, four levels have been set:
level1
: countrylevel2
: provinceslevel3
: cantonslevel4
: parishes
You can use the geojson and topojson files in your map on a webpage.
To visualize with d3:
d3
.geoIdentity()
.reflectY(true)
.fitSize([width, height], features)
Or using Plot in observablehq, see an example here
Clone or download the repo and start a terminal. Then run npm run prepublishOnly
to transform the downloaded zip files into topojson files.
If you need to make further adjustments (projection, simplification, quantization) you can change the prepublish
config file and run npm run prepublishOnly
again.
Note: Use the identity projection to visualize the map.
# simplification
Removes points to reduce the file size. Set to 3% by default.
# quantization
Removes information by reducing the precision of each coordinate. Set to 1e5
by default.
# ecuador-transverse_mercator-50k.json · Download
A TopoJSON file containing 4 levels of geometry. The geometry is quantized and simplified and projected.
# ec.objects.level4
Each parish has two properties:
- parish.id - the six-digit DPA_PARROQ code, such as
"010152"
- parish.properties.name - the district name, such as
"CUMBE"
The first two digits of the parish DPA_PARROQ code is the province code.
# ec.objects.level3
Each canton has two properties:
- canton.id - the four-digit canton code, such as
"0102"
- canton.properties.name - the province name, such as
"GIRON"
# ec.objects.provinces
The provinces has two properties:
- province.id - the string
"01"
- province.properties.name - the string
"AZUAY"
The original idea and implementation comes from Mike Bostock’s us-atlas and world-atlas.