Logo Lanfrica

davetaz/nigeria-map

Domain:

geospatial

Record type:

dataset
Creator:
dav
Host:
Burkina-Faso-map ================ The objective of this small project is to prepare a GeoJSON representation of Burkina Faso's administrative regions and departments to be offered by the African country's government together with the newly launched open data portal to its citizen. The source of the maps is MapMaker Ltd.'s "Map Library" service (read the Licence chapter below for more information). ##Map format conversion Conversion from MapMaker's shapefile to GeoJSON was performed using the ogr2ogr utility, part of GDAL, the open source geospatial data abstraction library. After unzipping MapMakers' original shapefiles in *data/raw*, Two simple commands are sufficient to perform the conversion: ogr2ogr -f data/processed/geoJSON burkinaFaso_regions.json data/raw/BUF-level_1_SHP/BUF-level_1.shp ogr2ogr -f data/processed/geoJSON burkinaFaso_departments.json data/raw/BUF_admin_SHP/BUF.shp Unfortunately MapMaker does not offer Burkina Faso provinces' map, although, with a little effort, that could be built by assembling together the boundaries of the departments that make one province. **It is important to consider the option to make the maps more suitable to bad or slow Internet connectivity** by creating smaller GeoJSON files. This is achieved by losing some of the detail in the regions and provinces' boundaries definition, adding the *-lco COORDINATE_PRECISION=[target_precision]* to the above commands, where *target_precision* is an integer >=1, e.g.: ogr2ogr -lco COORDINATE_PRECISION=3 -f geoJSON data/processed/burkinaFaso_regions.json data/raw/BUF-level_1_SHP/BUF-level_1.shp ogr2ogr -lco COORDINATE_PRECISION=3 -f geoJSON data/processed/burkinaFaso_departments.json data/raw/BUF_admin_SHP/BUF.shp The bigger the value used, the less detail is lost in creating the GeoJSON file. A value of 3 was used for the production of the GeoJSON files distributed with this project. See Bjørn Sandvik's great blog post "How to minify GeoJSON files?" for more detail. ##Addin …