Sophie

Sophie

distrib > Fedora > 13 > i386 > by-pkgid > dc303dcad9fdd039290b4e78a58ed938 > files > 718

python-matplotlib-0.99.1.2-4.fc13.i686.rpm

from matplotlib import mlab
from pylab import figure, show

a = mlab.csv2rec('../data/msft.csv')
a.sort()
print a.dtype

fig = figure()
ax = fig.add_subplot(111)
ax.plot(a.date, a.adj_close, '-')
fig.autofmt_xdate()

# if you have xlwt installed, you can output excel
import mpl_toolkits.exceltools as exceltools
exceltools.rec2excel(a, 'test.xls')
show()