Matplotlib is a python library used to create 2D graphs and plots by using python scripts. ... It supports a very wide variety of graphs and plots namely - histogram, bar charts, power spectra, error charts etc. It is used along with NumPy to provide an environment that is an effective open source alternative for MatLab.