For an overview and comparison of plotting options in Python, the places to start are Jake VanderPlas talk The Python Visualization Landscape given at Pycon 2017,
https://youtu.be/FytuB8nFHPQ. Also an article with examples by Dan Saber A Dramatic Tour through Python's Data Visualization Landscape (including ggplot and Altair)
https://dsaber.com/2016/10/02/a-dramatic-tour-through-pythons-data-visualization-landscape-including-ggplot-and-altair/Generally
1. Matplotlib. This is the baseline standard. You can do anything you can think of, but it may be very complicated. So there are a few libraries that exist to provide more compact and expressive access to this.
2. Then some libraries trying to make Matplotlib easier to work with
pandas. If you are using pandas to provide data frames anyway, pandas provides simple plotting given the fact that your data is in dataframes. I will use this for exploratory data analysis, then when I'm pretty sure what type of charts I want to use, switch to something else (seaborn, plotnine, matplotlib)
Seaborn. A more expressive chart specification. Not as far as learning a grammar of graphics, but trying to make a well defined subset of Matplotlib easy to work with.
3. For those of us who come from R, there are some packages that implement a grammar of graphics (a la ggplot2). The general idea is to separate the specification of the plot from the data, so you can swap out data as needed, and when developing a chart, you can switch visualizations without starting from scratch. There are a couple packages that pretend to be a grammar (they really are API translaters, which is not the same thing. Implementation on grammar of graphics include
plotnine - implementation of a grammar of graphics. For people coming from R, they reproduced (generally) the API (function names and usage) in addition to implementing the grammar.
Altair - I actually don't know anything about it, but Jake Vanderplas and Dan Saber seem to like it in their overviews.
4. interactive plots in the browser. A last group is if you are trying to create interactive plots (you are building a data exploration tool for someone in a web interface). So your client can do things like zoom in, zoom around, and generally play with plot options live.
bokeh - by same
plotly (commercial, but most of it is available in the free version)
------------------------------
Louis Luangkesorn
Assistant Professor
Department of Industrial Engineering
University of Pittsburgh
Pittsburgh PA
------------------------------
Original Message:
Sent: 01-25-2018 02:29
From: Varalakshmi Tyaggarajan
Subject: Plots using Python
Hello,
I am trying to get my hands dirty with Python. It is impressive with quite a number of sophisticated packages with a wide online support.
Looking out for packages recommendation for plots, especially was wondering to create overlay histograms.
------------------------------
Varalakshmi Tyaggarajan
University of Washington-Tacoma
Tacoma WA
------------------------------