- Matplotlib 3.0 Cookbook
- Srinivasa Rao Poladi
- 87字
- 2021-08-13 15:16:10
Getting ready
We will be using the familiar Iris dataset for this example. We will first create a correlation matrix and apply a standard colormap to see how it looks. We saw the same correlation matrix plotted as a heatmap in Chapter 2, Getting Started with Basic Plots. There, we used the hot colormap, but we did not go into the details regarding colormaps. We will explain that here.
Import the following required libraries:
import matplotlib.pyplot as plt
import pandas as pd
import numpy as np