It is a multiplatform data visualization library built on NumPy arrays, and they are designed to work with the broader SciPy stack.
Matplotlib is specifically good for creating basic graphs like line charts, bar charts, histograms and many more.
One of Matplotlib’s most important features is its ability to play well with many operating systems and graphics backends.
Matplotlib supports dozens of backends and output types, which means you can count on it to work regardless of which operating system you are using or which output format you wish.
This cross-platform, everything-to-everyone approach has been one of the great strengths of Matplotlib.
Pandas is an open source high-performance, easy-to-use library providing data structures, such as dataframes, and data analysis tools like the visualization tools we will use in this article.
Pandas Visualization makes it really easy to create plots out of a pandas dataframe and series.
It also has a higher level API than Matplotlib and therefore we need less code for the same results.
Seaborn is a Python data visualization library based on Matplotlib. It provides a high-level interface for creating attractive graphs.
Seaborn has a lot to offer. You can create graphs in one line that would take you multiple tens of lines in Matplotlib.
Its standard designs are awesome and it also has a nice interface for working with pandas dataframes
Below is the code that shows how to do this with pandas.
import numpy as np
import pandas as ps
from pandas.tools.plotting import scatter_matrix
data = ps.DataFrame(np.random.randn(100, 10), columns=['A1', 'A2', 'A3','A4','A5','A6','A7','A8','A9','A10'])
#Plotting using pandas
scatter_matrix(data, alpha=0.4, figsize=(5, 5), diagonal='kde')
You may change the plot over the time, for each instant you plot a different "dimension" of the dataframe. You can do plots that change over the time, you may adjust it according to your use.
import matplotlib.pyplot as mpl
import numpy as np
figure = mpl.figure()
d = figure.add_subplot(111)
x = np.arange(-3, 3, 0.01)
for n in range(15):
y = np.sin(np.pi*x*n) / (np.pi*x*n)
line, = d.plot(x, y)
Learn more about Matplotlib by watching this video tutorial:
If you want to be build successful data science career then enroll for best data science certification.