Hmm OK thanks. It seems I am using
In [3]: matplotlib.__version__
Out[3]: '0.98.5.3'
so by the sounds of it an outdated version? But your example will work on a
newer version?
What version of matplotlib are you using?
With 0.99.1.1 (and likely later) and also with the svn version, using
the bbox_inches="tight" actually produces an output with too small
margin.
With the svn version, following code should generate an output with an
adequate margin.
Otherwise, you cannot rely on bbox_inches features. Instead, you have
to manually adjust the size of the figure (and subplots_adjust).
Regards,
-JJ
t1=ax.text(0.5, -0.15, 'Longitude', transform=ax.transAxes,
ha='center', va='center')
t2=ax.text(-0.1, 0.5, 'Latitude', transform=ax.transAxes, ha=
'center', va='center', rotation='vertical')
#ax.set_title("Sign.Different: GSPW2 - Princeton")
fig.savefig('test.png', dpi=300, bbox_inches='tight',
bbox_extra_artists=[t1, t2])
--
View this message in context:
http://old.nabble.com/Removing-white-space-surrounding-plots-tp28824528p28843153.html
Sent from the matplotlib - users mailing list archive at Nabble.com.
------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
lucky parental unit. See the prize list and enter to win:
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Matplotlib-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-users