You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
(12) |
Sep
(12) |
Oct
(56) |
Nov
(65) |
Dec
(37) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(59) |
Feb
(78) |
Mar
(153) |
Apr
(205) |
May
(184) |
Jun
(123) |
Jul
(171) |
Aug
(156) |
Sep
(190) |
Oct
(120) |
Nov
(154) |
Dec
(223) |
2005 |
Jan
(184) |
Feb
(267) |
Mar
(214) |
Apr
(286) |
May
(320) |
Jun
(299) |
Jul
(348) |
Aug
(283) |
Sep
(355) |
Oct
(293) |
Nov
(232) |
Dec
(203) |
2006 |
Jan
(352) |
Feb
(358) |
Mar
(403) |
Apr
(313) |
May
(165) |
Jun
(281) |
Jul
(316) |
Aug
(228) |
Sep
(279) |
Oct
(243) |
Nov
(315) |
Dec
(345) |
2007 |
Jan
(260) |
Feb
(323) |
Mar
(340) |
Apr
(319) |
May
(290) |
Jun
(296) |
Jul
(221) |
Aug
(292) |
Sep
(242) |
Oct
(248) |
Nov
(242) |
Dec
(332) |
2008 |
Jan
(312) |
Feb
(359) |
Mar
(454) |
Apr
(287) |
May
(340) |
Jun
(450) |
Jul
(403) |
Aug
(324) |
Sep
(349) |
Oct
(385) |
Nov
(363) |
Dec
(437) |
2009 |
Jan
(500) |
Feb
(301) |
Mar
(409) |
Apr
(486) |
May
(545) |
Jun
(391) |
Jul
(518) |
Aug
(497) |
Sep
(492) |
Oct
(429) |
Nov
(357) |
Dec
(310) |
2010 |
Jan
(371) |
Feb
(657) |
Mar
(519) |
Apr
(432) |
May
(312) |
Jun
(416) |
Jul
(477) |
Aug
(386) |
Sep
(419) |
Oct
(435) |
Nov
(320) |
Dec
(202) |
2011 |
Jan
(321) |
Feb
(413) |
Mar
(299) |
Apr
(215) |
May
(284) |
Jun
(203) |
Jul
(207) |
Aug
(314) |
Sep
(321) |
Oct
(259) |
Nov
(347) |
Dec
(209) |
2012 |
Jan
(322) |
Feb
(414) |
Mar
(377) |
Apr
(179) |
May
(173) |
Jun
(234) |
Jul
(295) |
Aug
(239) |
Sep
(276) |
Oct
(355) |
Nov
(144) |
Dec
(108) |
2013 |
Jan
(170) |
Feb
(89) |
Mar
(204) |
Apr
(133) |
May
(142) |
Jun
(89) |
Jul
(160) |
Aug
(180) |
Sep
(69) |
Oct
(136) |
Nov
(83) |
Dec
(32) |
2014 |
Jan
(71) |
Feb
(90) |
Mar
(161) |
Apr
(117) |
May
(78) |
Jun
(94) |
Jul
(60) |
Aug
(83) |
Sep
(102) |
Oct
(132) |
Nov
(154) |
Dec
(96) |
2015 |
Jan
(45) |
Feb
(138) |
Mar
(176) |
Apr
(132) |
May
(119) |
Jun
(124) |
Jul
(77) |
Aug
(31) |
Sep
(34) |
Oct
(22) |
Nov
(23) |
Dec
(9) |
2016 |
Jan
(26) |
Feb
(17) |
Mar
(10) |
Apr
(8) |
May
(4) |
Jun
(8) |
Jul
(6) |
Aug
(5) |
Sep
(9) |
Oct
(4) |
Nov
|
Dec
|
2017 |
Jan
(5) |
Feb
(7) |
Mar
(1) |
Apr
(5) |
May
|
Jun
(3) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
|
2018 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2025 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
1
(20) |
2
(21) |
3
(21) |
4
(14) |
5
(8) |
6
(12) |
7
(16) |
8
(27) |
9
(39) |
10
(19) |
11
(12) |
12
(3) |
13
(3) |
14
(18) |
15
(14) |
16
(6) |
17
(7) |
18
(19) |
19
(5) |
20
(8) |
21
(24) |
22
(42) |
23
(12) |
24
(11) |
25
(16) |
26
(2) |
27
(4) |
28
(10) |
|
|
|
|
|
From: Paul I. <piv...@gm...> - 2011-02-25 23:59:17
|
Jeff Kowalczyk, on 2011-02-25 23:20, wrote: > I am trying to plot multiple series on one axes and a bar chart on a shared x, > new y axes. I'm using twinx. The following test code works, but I need to render > the bar plot *behind* the line plots. Can I somehow control zorder globally > within a figure? Hi Jeff, add these two lines before your plt.show() ax1.set_zorder(ax2.get_zorder()+1) # put ax in front of ax2 ax1.patch.set_visible(False) # hide the 'canvas' > > Alternatively, I could make the bar chart the first plot/axes ax1, but the > position for its y-axis must be on the right, the line chart's y-axis on the > left. Can this be controlled? ax1.yaxis.tick_right() ax2.yaxis.tick_left() best, -- Paul Ivanov 314 address only used for lists, off-list direct email at: http://pirsquared.org | GPG/PGP key id: 0x0F3E28F7 |
From: Jeff K. <jt...@ya...> - 2011-02-25 23:35:19
|
I am trying to plot multiple series on one axes and a bar chart on a shared x, new y axes. I'm using twinx. The following test code works, but I need to render the bar plot *behind* the line plots. Can I somehow control zorder globally within a figure? Alternatively, I could make the bar chart the first plot/axes ax1, but the position for its y-axis must be on the right, the line chart's y-axis on the left. Can this be controlled? Thanks. test.py: import matplotlib import numpy as np import matplotlib.pyplot as plt width_bar = 0.4 width_line = 6 for i in range(0,1): data = np.loadtxt(open('test.csv','r'), delimiter=',', dtype={'names': ('x','y1','y2','count'), 'formats': ('f4', 'i4', 'i4', 'i4', 'i4')}, usecols=(1,3,4,7)) x,y1,y2,count = data['x'],data['y1'],data['y2'],data['count'] fig = plt.figure() ax1 = fig.add_subplot(111) ax1.plot(x, y1, linewidth=width_line, zorder=3) ax1.plot(x, y2, linewidth=width_line, zorder=2) ax2 = ax1.twinx() ax2.bar(x, count, width=width_bar, color='0.9', zorder=1) plt.show() test.csv: 1,3.0,3.2,6,0,-10,29,8 1,3.5,3.5,20,12,-4,55,29 1,4.0,4.0,51,29,15,97,71 1,4.5,4.5,82,62,37,136,143 1,5.0,5.0,130,102,69,197,154 1,5.5,5.5,186,147,115,275,164 1,6.0,6.0,256,202,159,382,187 1,6.5,6.5,351,265,236,522,183 1,7.0,7.0,446,340,308,646,192 1,7.5,7.5,562,426,376,826,184 1,8.0,8.0,654,526,437,934,193 1,8.5,8.5,797,648,553,1080,190 1,9.0,9.0,940,765,648,1271,173 1,9.5,9.5,1111,910,782,1457,180 1,10.0,10.0,1240,1040,919,1564,199 1,10.5,10.5,1333,1175,1011,1655,209 1,11.0,11.0,1449,1285,1112,1775,210 1,11.5,11.5,1458,1366,1120,1793,173 1,12.0,12.0,1449,1427,1089,1799,156 1,12.5,12.5,1441,1460,1073,1809,136 1,13.0,13.0,1458,1483,1100,1803,174 1,13.5,13.5,1446,1491,1080,1809,134 1,14.0,14.0,1447,1497,1081,1814,139 1,14.5,14.5,1424,1498,1046,1810,112 1,15.0,15.0,1433,1500,1065,1817,85 1,15.5,15.5,1427,1500,1048,1819,66 1,16.0,15.9,1428,1500,1036,1817,41 1,16.5,16.5,1383,1500,990,1799,29 1,17.0,17.0,1379,1500,935,1820,29 1,17.5,17.5,1352,1500,899,1817,16 1,18.0,18.0,1347,1500,861,1825,9 1,18.5,18.4,1464,1500,1130,1818,4 1,19.0,18.9,1449,1500,1065,1819,3 |
From: Philipp A. <fly...@we...> - 2011-02-25 23:34:25
|
2011/2/25 Philipp A. <fly...@we...> > 2011/2/25 Benjamin Root <ben...@ou...> > >> On Fri, Feb 25, 2011 at 8:09 AM, Philipp A. <fly...@we...> wrote: >> >>> hi, >>> Axes3D from mpl_toolkits.mplot3d does not override set_*ticklabels. >>> this bug<http://sourceforge.net/tracker/index.php?func=detail&aid=2874110&group_id=80706&atid=560720>is about the issue. >>> to get a crude replacement, i have to do the following: >>> >>> for x, s in enumerate(ticks): >>>> ax.text3D(x, -.1, -.5, s) >>>> for a in ax.w_xaxis.get_ticklabels(): >>>> a.set_visible(False) >>>> >>> >>> is there a way to do better and hack my values into the real tick labels >>> (i bet they are drawn internally the same as text3D, but there is no way to >>> access the values)? >>> >>> >> In matplotlib in the development branch, I am able to call >> ax.w_xaxis.set_ticklabels() (or ax.w_yaxis, or ax.w_zaxis) and have the >> ticks show up appropriately. I have not tested earlier versions of >> matplotlib, though. Which version are you using? >> >> Admittedly, the control of the ticks is very poor in mplot3d. I hope to >> improve that over the next several months. >> >> Ben Root >> > > i use 0.99.3 both in university and at home, but somehow at home, > matplotlib complains about ValueError: Unknown projection '3d' at home. > > i’ll try 1.0.1 and report if it works. > update: i’ll see if a dev build does the trick tomorrow, as a local build of 1.0.1 doesn’t show the x/yticklabels and there doesn’t exist a function named set_zticklabels. |
From: Philipp A. <fly...@we...> - 2011-02-25 22:45:30
|
2011/2/25 Benjamin Root <ben...@ou...> > > > On Fri, Feb 25, 2011 at 8:09 AM, Philipp A. <fly...@we...> wrote: > >> hi, >> Axes3D from mpl_toolkits.mplot3d does not override set_*ticklabels. >> this bug<http://sourceforge.net/tracker/index.php?func=detail&aid=2874110&group_id=80706&atid=560720>is about the issue. >> to get a crude replacement, i have to do the following: >> >> for x, s in enumerate(ticks): >>> ax.text3D(x, -.1, -.5, s) >>> for a in ax.w_xaxis.get_ticklabels(): >>> a.set_visible(False) >>> >> >> is there a way to do better and hack my values into the real tick labels >> (i bet they are drawn internally the same as text3D, but there is no way to >> access the values)? >> >> > In matplotlib in the development branch, I am able to call > ax.w_xaxis.set_ticklabels() (or ax.w_yaxis, or ax.w_zaxis) and have the > ticks show up appropriately. I have not tested earlier versions of > matplotlib, though. Which version are you using? > > Admittedly, the control of the ticks is very poor in mplot3d. I hope to > improve that over the next several months. > > Ben Root > i use 0.99.3 both in university and at home, but somehow at home, matplotlib complains about ValueError: Unknown projection '3d' at home. i’ll try 1.0.1 and report if it works. |
From: Daniel M. <dan...@go...> - 2011-02-25 18:46:18
|
There is the one in the code, as suggested on the FAQ site :) >> thanks for pointing out the rcParams solution! For the time being, >> this seems an OK approach. I'd like to use the automatic solution, >> though > > There isn't one. |
From: Benjamin R. <ben...@ou...> - 2011-02-25 15:09:53
|
On Fri, Feb 25, 2011 at 8:09 AM, Philipp A. <fly...@we...> wrote: > hi, > Axes3D from mpl_toolkits.mplot3d does not override set_*ticklabels. > this bug<http://sourceforge.net/tracker/index.php?func=detail&aid=2874110&group_id=80706&atid=560720>is about the issue. > to get a crude replacement, i have to do the following: > > for x, s in enumerate(ticks): >> ax.text3D(x, -.1, -.5, s) >> for a in ax.w_xaxis.get_ticklabels(): >> a.set_visible(False) >> > > is there a way to do better and hack my values into the real tick labels > (i bet they are drawn internally the same as text3D, but there is no way to > access the values)? > > In matplotlib in the development branch, I am able to call ax.w_xaxis.set_ticklabels() (or ax.w_yaxis, or ax.w_zaxis) and have the ticks show up appropriately. I have not tested earlier versions of matplotlib, though. Which version are you using? Admittedly, the control of the ticks is very poor in mplot3d. I hope to improve that over the next several months. Ben Root |
From: Darren D. <dsd...@gm...> - 2011-02-25 14:42:33
|
On Fri, Feb 25, 2011 at 6:03 AM, Daniel Mader <dan...@go...> wrote: > Hi Goyo and Darren, > > thanks for pointing out the rcParams solution! For the time being, > this seems an OK approach. I'd like to use the automatic solution, > though There isn't one. |
From: Philipp A. <fly...@we...> - 2011-02-25 14:09:45
|
hi, Axes3D from mpl_toolkits.mplot3d does not override set_*ticklabels. this bug<http://sourceforge.net/tracker/index.php?func=detail&aid=2874110&group_id=80706&atid=560720>is about the issue. to get a crude replacement, i have to do the following: for x, s in enumerate(ticks): > ax.text3D(x, -.1, -.5, s) > for a in ax.w_xaxis.get_ticklabels(): > a.set_visible(False) > is there a way to do better and hack my values into the real tick labels (i bet they are drawn internally the same as text3D, but there is no way to access the values)? |
From: Yuri D'E. <wa...@us...> - 2011-02-25 12:20:17
|
In the following: <<<<<<<<<<< import matplotlib as mpl import matplotlib.figure import matplotlib.backends.backend_agg fig = mpl.figure.Figure() cvs = mpl.backends.backend_agg.FigureCanvasAgg(fig) fig.set_size_inches((20,20)) fig.suptitle("Horray!", fontsize=20) plot = fig.add_subplot(111) plot.set_title("Subtitle") plot.plot([1,2,3], [3,2,1]) fig.savefig("out.png", bbox_inches='tight') >>>>>>>>>>> suptitle is stripped from the figure. Of course the title is present if you unset bbox_inches, but that's unexpected behavior for me. Is this a bug? Thanks |
From: Jeff L. <lay...@at...> - 2011-02-25 12:19:43
|
On 02/23/2011 09:50 AM, Benjamin Root wrote: > On Wed, Feb 23, 2011 at 8:34 AM, Jeff Layton <lay...@at... > <mailto:lay...@at...>> wrote: > > Good morning, > > I'm looking for examples of creating a bar chart and then adding > a line chart on top of it (with the same y-axis). I haven't had > much luck with Google (probably using the wrong search terms). > > Thanks! > > Jeff > > > Jeff, > > You should be able to just call the bar() function and then call the > plot() function using the same axes object. For example (untested): > > import numpy as np > import matplotlib.pyplot as plt > > > fig = plt.figure() > ax = fig.gca() > > xs = np.arange(10) > ys = np.random.rand(10) > > ax.bar(xs, ys) > ax.plot(xs, ys) > > plt.show() > > > I hope that helps! > Ben Root That worked perfectly! I guess I was looking for something more complicated and it was that simple. Thanks! Jeff |
From: Daniel M. <dan...@go...> - 2011-02-25 11:03:42
|
Hi Goyo and Darren, thanks for pointing out the rcParams solution! For the time being, this seems an OK approach. I'd like to use the automatic solution, though, but this does not seem to work: import matplotlib.pyplot as plt import matplotlib.transforms as mtransforms import numpy,pylab,matplotlib.ticker as mtick x = numpy.linspace(0,10,1000) y = numpy.exp(x) pylab.rcdefaults() def on_draw(event): bboxes = [] for label in labels: bbox = label.get_window_extent() # the figure transform goes from relative coords->pixels and we # want the inverse of that bboxi = bbox.inverse_transformed(fig.transFigure) bboxes.append(bboxi) # this is the bbox that bounds all the bboxes, again in relative # figure coords bbox = mtransforms.Bbox.union(bboxes) if fig.subplotpars.left < bbox.width: # we need to move it over fig.subplots_adjust(left=1.1*bbox.width) # pad a little fig.canvas.draw() return False fig = pylab.figure(figsize=(5,3)) ax = fig.add_subplot(111) ax.set_yscale('log') ax.yaxis.set_major_formatter(mtick.FormatStrFormatter('%d')) ax.set_xlabel('asdf') ax.set_ylabel('qwer') ax.plot(x,y) labels = ax.get_yticklabels() fig.canvas.mpl_connect('draw_event', on_draw) fig.savefig('example_mpl-ticker_2') 2011/2/25 Darren Dale <dsd...@gm...>: > On Tue, Feb 22, 2011 at 4:23 AM, Daniel Mader > <dan...@go...> wrote: >> Hi, >> >> there has been a similar question recently but I couldn't figure out >> if or how this is solved: >> >> I'd like to reduce the figure size so that I can add it to a LaTeX >> document without scaling (PDF output with LaTeX font rendering). For >> that, I need to adapt the font sizes, too. >> >> Unfortunately, the canvas is not properly scaled so that the axis >> labels and the possibly the tick marks are cut off. >> >> Is this a bug, feature, design flaw? How can I properly work around >> it, i.e. reduce the graph automatically for a given figsize/font size >> combination so that everything fits on the figure? >> >> An example follows to demonstrate, thanks in advance > > I use matplotlib for this purpose pretty frequently. A few tricks: > > from http://matplotlib.sourceforge.net/users/customizing.html : > # note that font.size controls default text sizes. To configure > # special text sizes tick labels, axes, labels, title, etc, see the rc > # settings for axes and ticks. Special text sizes can be defined > # relative to font.size, using the following values: xx-small, x-small, > # small, medium, large, x-large, xx-large, larger, or smaller > > # specify the figure canvas size, in inches > figure(figsize=(3.4, 4)) > > # place the axes in the figure window > # specifying (left, bottom, width, height) as fraction of figure size > # adjust those positions to make enough room for tick and axis labels > axes([0.15, 0.12, 0.8, 0.83]) > > Specify the dpi for you screen, so the figure rendered on your screen > is the correct size. This is figure.dpi, best to set it in > matplotlibrc. > > Darren > -- Zugallistr. 11/14 5020 Salzburg M_at +43 699 10 54 54 53 T_at +43 662 841635 M_de +49 179 2300317 E dan...@go... |
From: Paul L. <pau...@ii...> - 2011-02-25 10:14:48
|
Hi Benjamin, > > On Wed, 16 Feb 2011 03:07:25 AM you wrote: > > > I have not figured out what is causing the difference between my > > > computers. > > > This might be backend-dependent (and maybe version-dependent). Have > > > you tested your code on different backends? Sorry for my delay in replying. I have had a busy week. I've now tested my PC running OpenSUSE 11.2 with python-matplotlib-1.0.1-20.1.x86_64. I ran ipython -pylab with various values for "backend=" in the matplotlibrc file. The results for all listed backends follow. Best, Paul # No figures are displayed: Agg,Cairo,GDK,PS,PDF,SVG,Template # Bug: Last plot is displayed in all figures: GTK,GTKAgg,GTKCairo,TkAgg,WXAgg # Two Bugs: Figures remain blank until last plot completed. # Last plot is displayed in all figures. Qt4Agg # Failed with error message: CocoaAgg # The CococaAgg backend required PyObjC to be installed! # (currently testing v1.3.7) FltkAgg #ImportError: No module named fltk MacOSX #ImportError: cannot import name _macosx QtAgg # RuntimeError: the sip module implements API v8.0 to v8.1 but the qt module requires API v7.1 WX # NotImplementedError: wx.GraphicsContext is not available on this platform. |
From: Michele M. <mat...@gm...> - 2011-02-25 01:42:19
|
Following up, after a bit of research... It seems it's alla about QString (which is gone in api 2) it is suggested to convert the QString into a unicode python2 string http://wiki.python.org/moin/PortingPythonToPy3k/PyQt4 Do you think could be the way to go for the qt backend? Cheers, Michele. On Fri, Feb 25, 2011 at 12:30 AM, Michele Mattioni <mat...@gm...> wrote: > Dear list, > > I'm trying to to use matplotlib in a Qt application which needs the > sip API set to 2 > > import sip > sip.setapi('QString', 2) > > However if I do this I get this error > > ImportError: cannot import name QString > > I'm wondering if I'm the first to stumble upon this one, or this is a > known solution. > > Below the whole Traceback. > > Thanks, > Michele. > > > In [3]: import sip > > In [4]: sip.setapi('QString', 2) > > In [5]: import matplotlib.pyplot as plt > --------------------------------------------------------------------------- > ImportError Traceback (most recent call last) > > /home/mattions/Work/model/MSN/Neuronvisio/examples/<ipython console> > in <module>() > > /usr/lib/pymodules/python2.6/matplotlib/pyplot.py in <module>() > 93 > 94 from matplotlib.backends import pylab_setup > ---> 95 new_figure_manager, draw_if_interactive, show = pylab_setup() > 96 > 97 @docstring.copy_dedent(Artist.findobj) > > /usr/lib/pymodules/python2.6/matplotlib/backends/__init__.pyc in pylab_setup() > 23 backend_name = 'matplotlib.backends.%s'%backend_name.lower() > 24 backend_mod = __import__(backend_name, > ---> 25 globals(),locals(),[backend_name]) > 26 > 27 # Things we pull in from all backends > > > /usr/lib/pymodules/python2.6/matplotlib/backends/backend_qt4agg.py in > <module>() > 10 > 11 from backend_agg import FigureCanvasAgg > ---> 12 from backend_qt4 import QtCore, QtGui, FigureManagerQT, > FigureCanvasQT,\ > 13 show, draw_if_interactive, backend_version, \ > 14 NavigationToolbar2QT > > /usr/lib/pymodules/python2.6/matplotlib/backends/backend_qt4.py in <module>() > 14 from matplotlib.mathtext import MathTextParser > 15 from matplotlib.widgets import SubplotTool > ---> 16 import matplotlib.backends.qt4_editor.figureoptions as figureoptions > 17 > 18 try: > > /usr/lib/pymodules/python2.6/matplotlib/backends/qt4_editor/figureoptions.py > in <module>() > 9 import os.path as osp > 10 > ---> 11 import matplotlib.backends.qt4_editor.formlayout as formlayout > 12 from PyQt4.QtGui import QIcon > 13 > > /usr/lib/pymodules/python2.6/matplotlib/backends/qt4_editor/formlayout.py > in <module>() > 57 QDateEdit, QDateTimeEdit, QFont, QFontComboBox, > 58 QFontDatabase, QGridLayout) > ---> 59 from PyQt4.QtCore import (Qt, SIGNAL, SLOT, QSize, QString, > 60 pyqtSignature, pyqtProperty) > 61 from datetime import date > > ImportError: cannot import name QString > |
From: Michele M. <mat...@gm...> - 2011-02-25 00:30:19
|
Dear list, I'm trying to to use matplotlib in a Qt application which needs the sip API set to 2 import sip sip.setapi('QString', 2) However if I do this I get this error ImportError: cannot import name QString I'm wondering if I'm the first to stumble upon this one, or this is a known solution. Below the whole Traceback. Thanks, Michele. In [3]: import sip In [4]: sip.setapi('QString', 2) In [5]: import matplotlib.pyplot as plt --------------------------------------------------------------------------- ImportError Traceback (most recent call last) /home/mattions/Work/model/MSN/Neuronvisio/examples/<ipython console> in <module>() /usr/lib/pymodules/python2.6/matplotlib/pyplot.py in <module>() 93 94 from matplotlib.backends import pylab_setup ---> 95 new_figure_manager, draw_if_interactive, show = pylab_setup() 96 97 @docstring.copy_dedent(Artist.findobj) /usr/lib/pymodules/python2.6/matplotlib/backends/__init__.pyc in pylab_setup() 23 backend_name = 'matplotlib.backends.%s'%backend_name.lower() 24 backend_mod = __import__(backend_name, ---> 25 globals(),locals(),[backend_name]) 26 27 # Things we pull in from all backends /usr/lib/pymodules/python2.6/matplotlib/backends/backend_qt4agg.py in <module>() 10 11 from backend_agg import FigureCanvasAgg ---> 12 from backend_qt4 import QtCore, QtGui, FigureManagerQT, FigureCanvasQT,\ 13 show, draw_if_interactive, backend_version, \ 14 NavigationToolbar2QT /usr/lib/pymodules/python2.6/matplotlib/backends/backend_qt4.py in <module>() 14 from matplotlib.mathtext import MathTextParser 15 from matplotlib.widgets import SubplotTool ---> 16 import matplotlib.backends.qt4_editor.figureoptions as figureoptions 17 18 try: /usr/lib/pymodules/python2.6/matplotlib/backends/qt4_editor/figureoptions.py in <module>() 9 import os.path as osp 10 ---> 11 import matplotlib.backends.qt4_editor.formlayout as formlayout 12 from PyQt4.QtGui import QIcon 13 /usr/lib/pymodules/python2.6/matplotlib/backends/qt4_editor/formlayout.py in <module>() 57 QDateEdit, QDateTimeEdit, QFont, QFontComboBox, 58 QFontDatabase, QGridLayout) ---> 59 from PyQt4.QtCore import (Qt, SIGNAL, SLOT, QSize, QString, 60 pyqtSignature, pyqtProperty) 61 from datetime import date ImportError: cannot import name QString |
From: Darren D. <dsd...@gm...> - 2011-02-25 00:18:40
|
On Tue, Feb 22, 2011 at 4:23 AM, Daniel Mader <dan...@go...> wrote: > Hi, > > there has been a similar question recently but I couldn't figure out > if or how this is solved: > > I'd like to reduce the figure size so that I can add it to a LaTeX > document without scaling (PDF output with LaTeX font rendering). For > that, I need to adapt the font sizes, too. > > Unfortunately, the canvas is not properly scaled so that the axis > labels and the possibly the tick marks are cut off. > > Is this a bug, feature, design flaw? How can I properly work around > it, i.e. reduce the graph automatically for a given figsize/font size > combination so that everything fits on the figure? > > An example follows to demonstrate, thanks in advance I use matplotlib for this purpose pretty frequently. A few tricks: from http://matplotlib.sourceforge.net/users/customizing.html : # note that font.size controls default text sizes. To configure # special text sizes tick labels, axes, labels, title, etc, see the rc # settings for axes and ticks. Special text sizes can be defined # relative to font.size, using the following values: xx-small, x-small, # small, medium, large, x-large, xx-large, larger, or smaller # specify the figure canvas size, in inches figure(figsize=(3.4, 4)) # place the axes in the figure window # specifying (left, bottom, width, height) as fraction of figure size # adjust those positions to make enough room for tick and axis labels axes([0.15, 0.12, 0.8, 0.83]) Specify the dpi for you screen, so the figure rendered on your screen is the correct size. This is figure.dpi, best to set it in matplotlibrc. Darren |
From: Tommy G. <tg...@ma...> - 2011-02-25 00:00:48
|
Is there a 64bit installer of matplotlib for mac os x available? Cheers Tommy |