我已經開始與matplot和管理的一些基本情節,但現在我覺得很難發現如何做一些東西,我現在:(Matplotlib - 全球傳說和標題一旁的次要情節
我實際的問題是如何需要將一個全局標題和全局圖例放在一個帶有子圖的圖上
我正在做2x3子圖,其中有很多不同顏色的圖形(大約200)。像
def style(i, total):
return dict(color=jet(i/total),
linestyle=["-", "--", "-.", ":"][i%4],
marker=["+", "*", "1", "2", "3", "4", "s"][i%7])
fig=plt.figure()
p0=fig.add_subplot(321)
for i, y in enumerate(data):
p0.plot(x, trans0(y), "-", label=i, **style(i, total))
# and more subplots with other transN functions
(對此有何看法?:))每個子圖具有相同的風格功能。
現在我試圖讓所有的小插圖的全球標題,也是一個解釋所有風格的全球傳奇。此外,我需要使字體很小,以適應所有200種風格(我不需要完全獨特的風格,但至少有一些嘗試)
有人可以幫我解決這個任務嗎?
全球標題:http://matplotlib.sourceforge.net/examples/pylab_examples/newscalarformatter_demo.html –