I need to draw two overlapping ellipses and the current code puts the edges of the second ellipse atop the first ellipse. Here is the code:
from matplotlib.pyplot import figure, show
from matplotlib import patches
fig = figure()
ax = fig.add_subplot(111)
ell = patches.Ellipse((0.15, 0.7), .3, .1, angle = 25, facecolor = 'white', edgecolor = 'gray', linewidth = 2, transform=ax.transAxes)
ax.add_artist(ell)
ell = patches.Ellipse((0.30, 0.7), .3, .1, angle = -25, facecolor = 'white', edgecolor = 'gray', linewidth = 2, transform=ax.transAxes)
ax.add_artist(ell)
show()
This produces a figure like the first figure at How to join overlapping circles? (I can't post my own figures here) while I want something like the second figure.
Is there a solution for this problem in matplotlib?