sjpfenninger / vis-tutorial

Tutorial on visualising data in Python: matplotlib, pandas, seaborn, plotly...

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Openmod visualisation tutorial

Authors: Bryn Pickering, Stefan Pfenninger

License: MIT

About

A tutorial on how to visualise data with Python, consisting of three Jupyter Notebooks:

  • 01-matplotlib.ipynb shows how to use matplotlib, the workhorse of plotting in Python, together with pandas and seaborn.
  • 01-matplotlib-exercise.ipynb contains a single exercise on the basics of matplotlib, intended to cover the first half of the 01-matplotlib.ipynb notebook.
  • 02-web-based.ipynb introduces Plotly and Bokeh, modern web-based libraries which make it very easy to create interactive visualisations.
  • 03-touching-up.ipynb shows how to save vector graphics from matplotlib, Plotly or Bokeh for final touching up in a separate tool, for example the free and open-source Inkscape.
  • 04-maps.ipynb shows some ways to plot maps.

Setup

1. Install the Anaconda Python distribution

Download the Anaconda Python distribution and run the downloaded installer:

https://www.anaconda.com/download/

Make sure you download the Python 3 version.

2. Create an environment

Once Anaconda is installed, create a new conda environment with the required packages, by running the following command in a terminal (Linux or macOS) or a command-line window (Windows), making sure you run this command inside the directory containing our requirements.yml file:

conda env create -f requirements.yml

3. Ensure that you can successfully run a Jupyter Notebook

If you are unfamiliar with the Jupyter Notebook, have a look at this quick start guide, in particular the section on running the notebook.

During the tutorial session we will not have time to solve installation problems, so make sure that you are able to run the Jupyter Notebook before you arrive.

Data

We are using data made available from the Open Power System Data project for this tutorial. These datasets can be found in the data subdirectory and are based on the following download links:

Other libraries we don't cover here

About

Tutorial on visualising data in Python: matplotlib, pandas, seaborn, plotly...

License:MIT License


Languages

Language:Jupyter Notebook 100.0%Language:Python 0.0%