Matplotlib Bar Plot

How to use the Matplotlib library to create a bar plot

Python
import matplotlib.pyplot as plt

# Data
categories = ['A', 'B', 'C', 'D', 'E']
values = [10, 15, 7, 12, 9]

# Create bar plot
plt.bar(categories, values)
plt.xlabel('Categories')
plt.ylabel('Values')
plt.title('Bar Plot')
plt.show()
CTRL + ENTER to send