Exploratory data analysis and visualization of a small geospatial dataset.
Explore the interactive map.
Built with:
- Geopandas
- Shapely
- PyProj
- Cartopy
- Folium
Source: Regione Toscana – Beni confiscati alla criminalità organizzata (January 2018).
The dataset is released under the CC BY-SA 4.0 license.
Binder builds a docker image from a git repository + commit, so you can run the notebook beni-confiscati.ipynb
in the cloud, without installing anything on your machine.
If you want to run the notebook locally, you need to create a conda environment. You can obtain the conda package manager by installing a Python distribution like Miniconda or Anaconda.
Create and activate a new conda environment:
conda create --name beni-confiscati python=3.6 --yes
source activate beni-confiscati
Install all the dependencies (this might take a while, go grab a cup of coffee):
conda install -c conda-forge jupyter numpy pandas geopandas pyproj shapely cartopy folium -y
If you run into issues when importing fiona
, try downgrading it to 1.7.9
:
conda install -c conda-forge fiona=1.7.9
When all dependencies have been installed, run the notebook:
jupyter notebook
Note: I decided to included the dataset in the repository, so you don't have to go find it by yourself. After all it is just ~200KB.
You can freeze your environment with:
conda env export > environment.yml
To remove this conda environment, run:
conda env remove -n beni-confiscati