Goal
I am trying to simply plot a rectangle with a given color using matplotlib.
What I have tried
import matplotlib
fig = plt.figure()
ax = fig.add_subplot(111)
rect = matplotlib.patches.Rectangle((50, 100), 40, 30, linewidth=1, edgecolor='r', facecolor='red')
ax.add_patch(rect)
The issue
I am getting an empty figure