SourceForge logo
SourceForge logo
Menu

matplotlib-users — Discussion related to using matplotlib

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
(2)
2
(4)
3
(9)
4
(12)
5
(12)
6
(7)
7
(8)
8
(4)
9
(2)
10
(9)
11
(6)
12
(1)
13
(20)
14
(13)
15
(9)
16
(3)
17
(12)
18
(16)
19
(14)
20
(12)
21
(15)
22
(11)
23
(5)
24
(7)
25
(7)
26
(8)
27
(11)
28
(10)
29
(1)
30
(3)
31
(6)





Showing 9 results of 9

From: Michael D. <md...@st...> - 2011年10月10日 23:08:28
How does one reproduce this?
Mike
On 10/09/2011 04:32 AM, Nils Wagner wrote:
> File
> "/home/nwagner/local/lib64/python2.6/site-packages/matplotlib/backends/backend_qt4.py",
> line 463, in edit_parameters
> figureoptions.figure_edit(axes, self)
> File
> "/home/nwagner/local/lib64/python2.6/site-packages/matplotlib/backends/qt4_editor/figureoptions.py",
> line 132, in figure_edit
> icon=get_icon('qt4_editor_options.svg'),
> apply=apply_callback)
> File
> "/home/nwagner/local/lib64/python2.6/site-packages/matplotlib/backends/qt4_editor/formlayout.py",
> line 511, in fedit
> dialog = FormDialog(data, title, comment, icon,
> parent, apply)
> File
> "/home/nwagner/local/lib64/python2.6/site-packages/matplotlib/backends/qt4_editor/formlayout.py",
> line 416, in __init__
> parent=self)
> File
> "/home/nwagner/local/lib64/python2.6/site-packages/matplotlib/backends/qt4_editor/formlayout.py",
> line 390, in __init__
> widget = FormComboWidget(data, comment=comment,
> parent=self)
> File
> "/home/nwagner/local/lib64/python2.6/site-packages/matplotlib/backends/qt4_editor/formlayout.py",
> line 368, in __init__
> widget = FormWidget(data, comment=comment,
> parent=self)
> File
> "/home/nwagner/local/lib64/python2.6/site-packages/matplotlib/backends/qt4_editor/formlayout.py",
> line 233, in __init__
> self.data = deepcopy(data)
> File "/usr/lib64/python2.6/copy.py", line 162, in
> deepcopy
> y = copier(x, memo)
> File "/usr/lib64/python2.6/copy.py", line 228, in
> _deepcopy_list
> y.append(deepcopy(a, memo))
> File "/usr/lib64/python2.6/copy.py", line 162, in
> deepcopy
> y = copier(x, memo)
> File "/usr/lib64/python2.6/copy.py", line 235, in
> _deepcopy_tuple
> y.append(deepcopy(a, memo))
> File "/usr/lib64/python2.6/copy.py", line 162, in
> deepcopy
> y = copier(x, memo)
> File "/usr/lib64/python2.6/copy.py", line 228, in
> _deepcopy_list
> y.append(deepcopy(a, memo))
> File "/usr/lib64/python2.6/copy.py", line 162, in
> deepcopy
> y = copier(x, memo)
> File "/usr/lib64/python2.6/copy.py", line 292, in
> _deepcopy_inst
> state = deepcopy(state, memo)
> File "/usr/lib64/python2.6/copy.py", line 162, in
> deepcopy
> y = copier(x, memo)
> File "/usr/lib64/python2.6/copy.py", line 255, in
> _deepcopy_dict
> y[deepcopy(key, memo)] = deepcopy(value, memo)
> File "/usr/lib64/python2.6/copy.py", line 189, in
> deepcopy
> y = _reconstruct(x, rv, 1, memo)
> File "/usr/lib64/python2.6/copy.py", line 323, in
> _reconstruct
> y = callable(*args)
> File "/usr/lib64/python2.6/copy_reg.py", line 93, in
> __newobj__
> return cls.__new__(cls, *args)
> TypeError: instancemethod expected at least 2 arguments,
> got 0
>
> ------------------------------------------------------------------------------
> All of the data generated in your IT infrastructure is seriously valuable.
> Why? It contains a definitive record of application performance, security
> threats, fraudulent activity, and more. Splunk takes this data and makes
> sense of it. IT sense. And common sense.
> http://p.sf.net/sfu/splunk-d2dcopy2
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
From: Jeff W. <js...@fa...> - 2011年10月10日 21:37:48
On 10/9/11 6:38 AM, Filipe Pires Alvarenga Fernandes wrote:
> On Thu, Oct 6, 2011 at 14:50, Jeff Whitaker<js...@fa...> wrote:
>> On 9/29/11 9:44 AM, Filipe Pires Alvarenga Fernandes wrote:
>>> Hi I noticed that Basemap 1.0.2 will replace the old pyshapelib with
>>> the pure python shapelib.py. However, that did break some of my
>>> scripts when I use custom shapefiles.
>>>
>>> Here is a picture from Basemap 1.0.1,
>>>
>>> http://imageshack.us/photo/my-images/69/basemap101.png/
>>>
>>> and here the same script under Basemap 1.0.2,
>>>
>>> http://imageshack.us/photo/my-images/854/basemap102.png/
>>>
>>> and here is the script:
>>> http://pastebin.com/WfePCFJi
>>>
>>> It probably has something to do with the way shapelib.py handle the
>>> lines, As soon as I have some time I'll take a better look into that,
>>> but I would like to ask if anyone has seen this before and/or if you
>>> have a suggestion/solution for it.
>>>
>>> Thanks, Filipe
>> Filipe: Were you able to resolve this? I just updated shapefile.py in the
>> git repository, so you might try again on the off chance a bug was fixed.
>> If the problem still persists, please point me to a shapefile that triggers
>> the problem.
>>
>> -Jeff
> Thanks, but the problem persists. I haven't got time to look into it
> yet, as soon as I do I'll get back to you.
>
> Regarding the shapefile, I do not remember the official source
> anymore, but you can get a copy here:
> https://build.opensuse.org/package/files?package=python-basemap&project=home%3Aocefpaf
>
> Thanks again, Filipe
>
Filipe: I believe I've fixed it - your shapefile now displays correctly 
for me. Please try updating from https://github.com/matplotlib/basemap.
-Jeff
-- 
Jeffrey S. Whitaker Phone : (303)497-6313
Meteorologist FAX : (303)497-6449
NOAA/OAR/PSD R/PSD1 Email : Jef...@no...
325 Broadway Office : Skaggs Research Cntr 1D-113
Boulder, CO, USA 80303-3328 Web : http://tinyurl.com/5telg
From: Benjamin R. <ben...@ou...> - 2011年10月10日 17:20:18
On Fri, Oct 7, 2011 at 3:40 PM, Paul Hobson <pmh...@gm...> wrote:
> Hey folks,
>
> I'm working on a patch to axes.boxplot that will allow the user to
> manually specify the median and confidence intervals (notches) on a
> boxplot. My need for this arises since I compute the notch locations
> using the BCa-method, which depends on Scipy.
>
> My question relates to how to best have users input their predefined
> median and its confidence interval. In my use case, I'm always calling
> boxplot one data set at a time and so it has made sense for me pass
> the values as a dictionary to my locally-modified boxplot function.
> This is probably a quite unique use case.
>
> In the more general use case where an arbitrary number of boxplots
> will be generated on a single axes object, what would be the best
> method of input? My initial though is to specify a list-of-tuples in
> the form: [(lower1, median1, upper1), (lower2, median2, upper2), ...,
> (lowerN, medianN, upperN)]. The modified function signature would be:
> def boxplot(self, x, notch=0, sym='b+', vert=1, whis=1.5,
> positions=None, widths=None, patch_artist=False,
> bootstrap=None, manualVals=None):
>
> The other best option that comes to mind would be to pass each value
> as an individual numpy array with dimensions that are compatible with
> the data (x), i.e.,
> def boxplot(self, x, notch=0, sym='b+', vert=1, whis=1.5,
> positions=None, widths=None, patch_artist=False,
> bootstrap=None, lowerCIs=None, medians=None, upperCIs=None):
>
> This seems a bit cumbersome both to use and implement, though quite
> flexible as the user would not be forced to supply all three arrays.
>
> Any advice, requests, or general input would be much appreciated.
>
> Cheers,
> -Paul H.
>
>
Just a thought to throw out there... maybe the call
signatures/functionalities of boxplot() and errorbar() should get merged?
To me, I imagine these kinds of plots as being two sides of the same coin.
Cheers!
Ben Root
From: Michael D. <md...@st...> - 2011年10月10日 16:37:11
Using anything but the CM and STIX fonts in mathtext ultimately leads to 
a world of pain and I consider it "unsupported", because there are 
custom tweaks to get the alignment working that end up being missing.
However, if you really want to try it you can set the following rcParams:
 mathtext.default: regular # Use the same font for math as regular text
 mathtext.fontset: custom # Don't pull any glyphs from cm or stix
Then you can write your string entirely in math syntax, eg.:
 r"$VCD_{strat} O_3 [DU]$"
Mike
On 10/10/2011 12:17 PM, Andreas H. wrote:
>>> I would like to use .otf fonts for typesetting text (axes, titles,
>>> labels,
>>> legends, ...) in matplotlib. Is this possible? If yes, how?
>> Yes. Put the font somewhere in your font search path. (Where that
>> would be depends on your platform, but for user-local fonts, use
>> "~/.fonts" on Linux, "~/Library/Fonts" on OS-X, I don't recall on
>> Windows, but Googling should give you something). You will need to
>> delete the matplotlib font cache so that it will discover new fonts.
>> This lives in "~/.matplotlib/fontList.cache" on Unix platforms. Then
>> you can change the default font family by setting the "font.family"
>> rcParam to the name of the font.
> Cool, this seems to work :)
>
> Now, I only have one issue:
>
> If I set a text, for example via
>
> ylabel(r"VCD$_{\sf strat}$ O$_{\sf 3}$ [DU]")
>
> the subscript "strat" actually gets typeset in my OTF font, but the subset
> "3" gets typeset in the standard math font (the fonts Cmr10 and Cmss10 get
> embedded in the PDF file). This doesn't look nice, because I am using
> MyriadPro, which is a sans-serif, while the CMR/CMSS fonts are serif fonts
> ...
>
> Any ideas how to solve this?
>
> Cheers!
> Andreas.
>
>
> ------------------------------------------------------------------------------
> All the data continuously generated in your IT infrastructure contains a
> definitive record of customers, application performance, security
> threats, fraudulent activity and more. Splunk takes this data and makes
> sense of it. Business sense. IT sense. Common sense.
> http://p.sf.net/sfu/splunk-d2dcopy1
> _______________________________________________
> Matplotlib-users mailing list
> Mat...@li...
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
From: Andreas H. <li...@hi...> - 2011年10月10日 16:17:53
>> I would like to use .otf fonts for typesetting text (axes, titles,
>> labels,
>> legends, ...) in matplotlib. Is this possible? If yes, how?
> Yes. Put the font somewhere in your font search path. (Where that
> would be depends on your platform, but for user-local fonts, use
> "~/.fonts" on Linux, "~/Library/Fonts" on OS-X, I don't recall on
> Windows, but Googling should give you something). You will need to
> delete the matplotlib font cache so that it will discover new fonts.
> This lives in "~/.matplotlib/fontList.cache" on Unix platforms. Then
> you can change the default font family by setting the "font.family"
> rcParam to the name of the font.
Cool, this seems to work :)
Now, I only have one issue:
If I set a text, for example via
 ylabel(r"VCD$_{\sf strat}$ O$_{\sf 3}$ [DU]")
the subscript "strat" actually gets typeset in my OTF font, but the subset
"3" gets typeset in the standard math font (the fonts Cmr10 and Cmss10 get
embedded in the PDF file). This doesn't look nice, because I am using
MyriadPro, which is a sans-serif, while the CMR/CMSS fonts are serif fonts
...
Any ideas how to solve this?
Cheers!
Andreas.
From: Michael D. <md...@st...> - 2011年10月10日 15:45:50
On 10/10/2011 08:25 AM, Andreas H. wrote:
> Hi,
>
> I would like to use .otf fonts for typesetting text (axes, titles, labels,
> legends, ...) in matplotlib. Is this possible? If yes, how?
Yes. Put the font somewhere in your font search path. (Where that 
would be depends on your platform, but for user-local fonts, use 
"~/.fonts" on Linux, "~/Library/Fonts" on OS-X, I don't recall on 
Windows, but Googling should give you something). You will need to 
delete the matplotlib font cache so that it will discover new fonts. 
This lives in "~/.matplotlib/fontList.cache" on Unix platforms. Then 
you can change the default font family by setting the "font.family" 
rcParam to the name of the font.
Note that matplotlib does not support all of the features of otf fonts, 
like glyph substitution etc. -- it really only uses the basic 
"TrueType-like" parts of the font file.
> If not directly, perhaps via XeTeX?
>
This is another avenue, and has the potential to use the advanced 
features of otf. I've never attempted this myself, but perhaps one of 
the other users on this list who uses usetex more often can comment.
Mike
From: Andreas H. <li...@hi...> - 2011年10月10日 12:42:18
Hi,
I would like to use .otf fonts for typesetting text (axes, titles, labels,
legends, ...) in matplotlib. Is this possible? If yes, how?
If not directly, perhaps via XeTeX?
Cheers,
Andreas.
From: Benjamin R. <ben...@ou...> - 2011年10月10日 04:58:51
This would only happen if the program explicitly calls for macosx backend
with the use() function, or you have macosx backend selected in your
.matplotlibrc file.
Ben Root
On Sunday, October 9, 2011, Shuo Deng <den...@gm...> wrote:
> Hi All,
>
> I am using a Ubuntu 10.04 machine (Linux 2.6.32-28-generic #55-Ubuntu SMP
Mon Jan 10 21:21:01 UTC 2011 i686 GNU/Linux)
>
> And I am running Matplotlib version 0.99.1.1.
>
> I got following errors when I am trying to run a program:
>
> Traceback (most recent call last):
> File "PS3_audionoise.py", line 11, in <module>
> import matplotlib.pyplot as p
> File "/usr/lib/pymodules/python2.6/matplotlib/pyplot.py", line 78, in
<module>
> new_figure_manager, draw_if_interactive, show = pylab_setup()
> File "/usr/lib/pymodules/python2.6/matplotlib/backends/__init__.py",
line 25, in pylab_setup
> globals(),locals(),[backend_name])
> File
"/usr/lib/pymodules/python2.6/matplotlib/backends/backend_macosx.py", line
20, in <module>
> from matplotlib.backends import _macosx
> ImportError: cannot import name _macosx
>
>
> Seems the _macosx is for Mac, not Ubuntu.
>
> I tried to install matplotlib both from source and using apt-get. But this
error happens every time. Does any one know how to fix this?
>
> Thanks!
>
>
From: Shuo D. <den...@gm...> - 2011年10月10日 04:51:37
Hi All,
I am using a Ubuntu 10.04 machine (Linux 2.6.32-28-generic #55-Ubuntu SMP
Mon Jan 10 21:21:01 UTC 2011 i686 GNU/Linux)
And I am running Matplotlib version 0.99.1.1.
I got following errors when I am trying to run a program:
Traceback (most recent call last):
 File "PS3_audionoise.py", line 11, in <module>
 import matplotlib.pyplot as p
 File "/usr/lib/pymodules/python2.6/matplotlib/pyplot.py", line 78, in
<module>
 new_figure_manager, draw_if_interactive, show = pylab_setup()
 File "/usr/lib/pymodules/python2.6/matplotlib/backends/__init__.py", line
25, in pylab_setup
 globals(),locals(),[backend_name])
 File "/usr/lib/pymodules/python2.6/matplotlib/backends/backend_macosx.py",
line 20, in <module>
 from matplotlib.backends import _macosx
ImportError: cannot import name _macosx
Seems the _macosx is for Mac, not Ubuntu.
I tried to install matplotlib both from source and using apt-get. But this
error happens every time. Does any one know how to fix this?
Thanks!

Showing 9 results of 9

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.
Thanks for helping keep SourceForge clean.
X





Briefly describe the problem (required):
Upload screenshot of ad (required):
Select a file, or drag & drop file here.
Screenshot instructions:

Click URL instructions:
Right-click on the ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies

Ad destination/click URL:

AltStyle によって変換されたページ (->オリジナル) /