Hello
import numpy as np import matplotlib.pyplot as plt x = np.arange(10) y = x**2 x
array([0, 1, 2, 3, 4, 5, 6, 7, 8, 9])
y
array([ 0, 1, 4, 9, 16, 25, 36, 49, 64, 81])
plt.plot(x,y)
[<matplotlib.lines.Line2D object at 0x044F5930>]
plt.show()
The question is: plt.plot() creates an object "matplotlib.lines.Line2D" but this object is not referenced. So this object should disapear from memory. But this doesn't happens since plt.show() draws the curve on a graphic window. So how does it work ? -- https://mail.python.org/mailman/listinfo/python-list