mgastner / cartogram-cpp

Cartogram generator in C++
MIT License
8 stars 4 forks source link

Additional features for cartogram comparisons #147

Open phongulus opened 2 years ago

phongulus commented 2 years ago

To generate an equal area map with the data embedded, run ./bin/cartogram ../sample_data/belgium/belgium.geojson ../sample_data/belgium/belgium_population2019.csv --insert_visual_variable --output_equal_area. The generated file can then be read into QGIS (Layer -> Add Layer -> Add Vector Layer) and exported as a Shapefile (right-click on the map layer on the bottom-left Layer panel > Export > Save Feature As). Note: when generating a Shapefile this way, do not change the CRS settings.

To compare two maps, run ./bin/cartogram ../sample_data/belgium/belgium.geojson ../sample_data/belgium/belgium_population2019.csv -c ./belgium_cartogram.geojson. The first file should be the original map, and the file after the -c flag should be the cartogram. No integrations will be done when the -c flag is used.