I'm trying to draw an ellipse on my plot in such a way to represent a cluster. The code below here plots the first picture. It is within a for loop, but it is not important
native_f1 = [some values here]
native_f2 = [some values here]
ax = plt.subplot(2, 2, index)
ax.scatter(native_f1, native_f2, s=40)
axes = plt.gca()
axes.set_xlim([min(native_f1) - 800, max(native_f1) + 800])
axes.set_ylim([min(native_f2) - 800, max(native_f2) + 800])
Now I'd like to obtain something like that:
How do I draw an ellipse based on the values that I use to plot these graphs ? Thank you