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
(9) |
2
(8) |
3
(6) |
4
(5) |
5
(10) |
6
(1) |
7
|
8
(5) |
9
(3) |
10
(12) |
11
(24) |
12
(28) |
13
(16) |
14
(3) |
15
(10) |
16
(17) |
17
(19) |
18
(10) |
19
(20) |
20
(7) |
21
(11) |
22
(7) |
23
(5) |
24
(4) |
25
(11) |
26
(19) |
27
(1) |
28
(1) |
29
(13) |
30
(7) |
31
(22) |
|
|
|
From: Jonathan S. <js...@cf...> - 2011-08-17 12:53:37
|
Attached are examples of the problem -- a PostScript file and the pdf that is created using ps2pdf. The y-axis is properly labeled in the ps file, but the part of the label using mathtext becomes invisible in the pdf. Jon On Wed, 2011-08-17 at 14:09 +0900, Jae-Joon Lee wrote: > Can you post an output eps file so that we can take a look? > Regards, > > -JJ > > > > On Wed, Aug 17, 2011 at 5:52 AM, Jonathan Slavin > <js...@cf...> wrote: > > Hi all, > > > > I've been making figures for a paper I'm writing (to be submitted to the > > ApJ). I'm using LaTeX and so need to use encapsulated PostScript for > > the figures. The problem is that when the paper is translated to pdf > > from PostScript, the mathtext in the figures disappears. The reason > > that I think this is a matplotlib issue is that it's never happened to > > me with eps figures created in different ways. It's clear that this > > must be related to fonts, but I'm not sure how to get around it. Should > > I set text.usetex to True? I have a feeling this issue must have come > > up before, but I haven't found anything obviously pertinent in the > > mailing list archives. > > > > Jon > > > > > > ------------------------------------------------------------------------------ > > Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > > user administration capabilities and model configuration. Take > > the hassle out of deploying and managing Subversion and the > > tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > > _______________________________________________ > > Matplotlib-users mailing list > > Mat...@li... > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > -- ______________________________________________________________ Jonathan D. Slavin Harvard-Smithsonian CfA js...@cf... 60 Garden Street, MS 83 phone: (617) 496-7981 Cambridge, MA 02138-1516 cell: (781) 363-0035 USA ______________________________________________________________ |
From: Eric F. <ef...@ha...> - 2011-08-17 08:13:01
|
On 08/16/2011 12:42 AM, Vlastimil Brom wrote: > 2011/8/16 Eric Firing<ef...@ha...>: >> On 07/25/2011 08:21 AM, Ben Breslauer wrote: >>> I think that I have found the problem here. Line2D.draw() (and I >>> presume other Artist subclasses) calls >>> >>> gc.set_foreground(self._color) >>> ... >>> gc.set_alpha(self._alpha) >>> >>> self._color is defined by the color kwarg, whether it be a hex value, >>> 3-tuple, 4-tuple, or something else. self._alpha is defined by the >>> alpha kwarg, but if the alpha kwarg is None, it is not overwritten with >>> color[3]. Therefore, using color=(R,G,B,A) does not set alpha >>> correctly. I'm not sure the best (i.e. most matplotlib-like) way to >>> change this so that the A value gets used iff alpha is None, but I've >>> attached a patch that does it one way (diff'ed against the github >>> master, commit 67b1cd650f574f9c53ce). I know the patch is less than >>> ideal, as it adds kwarg-specific handling into a place where none had >>> previously been done, and it's also in a for loop. Maybe it would be >>> better to do the checking along with the scalex and scaley pops? >> >> >> Alpha handling is a real can of worms; it has gotten better, but as you >> note, there are still problems. Unfortunately, I don't think your >> proposed solution will work in general, because self._color could be a >> 4-letter string, like "gray", in which case alpha would be set to "y", >> and that would not be good at all. I suspect the right place to solve >> the problem is down in the GraphicsContext--although I thought I had >> already straightened that out some time ago. >> ... >> >> Eric >> >>> >>> >>> Separately, I noticed that >>> backend_bases.GraphicsContextBase.set_foreground claims to only expect >>> an RGB definition, and not an RGBA definition. As such, I think that it >>> should call >>> >>> self._rgb = colors.colorConverter.to_rgb(fg) >>> >>> instead of >>> >>> self._rgb = colors.colorConverter.to_rgba(fg) >>> >>> since that will make self._rgb a 3-tuple instead of a 4-tuple. >>> >>> Ben >>> ... >>> > Just a remark for this recent proposed patch, as I unfortunately don't > know the implications for the whole codebase. > I believe, that the condition added in the patch > if len(line._color) == 4 and line._alpha == None: > could be adjusted to e.g.: > if isinstance(line._color, tuple) and len(line._color) == 4 and > line._alpha == None > > If the alpha value can be set in the color-tuple (for "#RRGGBBAA" some > parsing would be needed, if it is accepted). > Possibly the _alpha should be replace with tha alpha value of the > colour passed this way like > http://matplotlib.sourceforge.net/api/colors_api.html#matplotlib.colors.ColorConverter.to_rgba > "If arg is an RGBA sequence and alpha is not None, alpha will replace > the original A." > > But as has been suggested already, it might be better adressed in some > more general way, than in this single function. See https://github.com/matplotlib/matplotlib/pull/423 Eric > > regards, > vbr > > ------------------------------------------------------------------------------ > uberSVN's rich system and user administration capabilities and model > configuration take the hassle out of deploying and managing Subversion and > the tools developers use with it. Learn more about uberSVN and get a free > download at: http://p.sf.net/sfu/wandisco-dev2dev > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users |
From: Jae-Joon L. <lee...@gm...> - 2011-08-17 05:09:29
|
Can you post an output eps file so that we can take a look? Regards, -JJ On Wed, Aug 17, 2011 at 5:52 AM, Jonathan Slavin <js...@cf...> wrote: > Hi all, > > I've been making figures for a paper I'm writing (to be submitted to the > ApJ). I'm using LaTeX and so need to use encapsulated PostScript for > the figures. The problem is that when the paper is translated to pdf > from PostScript, the mathtext in the figures disappears. The reason > that I think this is a matplotlib issue is that it's never happened to > me with eps figures created in different ways. It's clear that this > must be related to fonts, but I'm not sure how to get around it. Should > I set text.usetex to True? I have a feeling this issue must have come > up before, but I haven't found anything obviously pertinent in the > mailing list archives. > > Jon > > > ------------------------------------------------------------------------------ > Get a FREE DOWNLOAD! and learn more about uberSVN rich system, > user administration capabilities and model configuration. Take > the hassle out of deploying and managing Subversion and the > tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2 > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |
From: Ben B. <bbr...@gm...> - 2011-08-17 02:30:39
|
On Tue, Aug 16, 2011 at 12:22 AM, Benjamin Root <ben...@ou...> wrote: > > > On Monday, August 15, 2011, Ben Breslauer <bbr...@gm...> wrote: > > Hi, > > > > Has anyone else noticed this behavior? For the devs, do you prefer a > github bug to the SF list? > > > > Ben > > I have not personally observed this, but usually, people don't specify rgba > tuples for plot. I think the lack of response is due to our focus on larger > bugs right now for the upcoming release. Therefore, it would probably be > best to file a bug report with your patch so that we have a record of it. > > The fuller patch might be more involved (consider scatter and other > functions). Plus, we would likely need to consider what to do if both an > rgba tuple and alpha were specified, > > As a rule of thumb, if we don't respond on list, file a bug report. > > Thanks for bringing this to our attention! > Ben Root Ben, Eric, and Vlastimil, Thanks for the responses. I will try and submit a bug report soon, and perhaps a patch if I can come up with something more complete, though obviously I don't know the matplotlib code base all that well. And I'll keep that rule of thumb in mind in the future. Ben |
From: Andre' Walker-L. <wal...@gm...> - 2011-08-17 00:12:19
|
Hi All, A question for a possible new feature for Matplotlib. First, in case there is a way to do it currently: I often find myself plotting data with errorbars, and I would like to be able to modify the marker, or marker size of each individual point separately. A (seemingly to me) natural way to do this would allow marker markersize markerfacecolor markeredgecolor etc accept arrays, as well as a single kwarg. As far as I can tell, if I have a set of data, and I want to make the markers with different sizes, the only way to do this is have a loop that calls each data point individually and assigns the marker features. 1 - am I mistaken? and if so, could someone instruct me how to achieve my goal 2 - does anyone else find this feature desirable? If so, could this be added to Matplotlib? I have not the coding experience to attempt this myself - but I imagine the simplest thing to do would be check if the marker, ms, etc are given single kwargs, or arrays. If single, everything happens as now. If array, then check the len of the array against the len of the data, and if the same, match the entries. Thanks, Andre |
From: Damon M. <D.M...@wa...> - 2011-08-16 23:44:11
|
> Hi all, > > I've been making figures for a paper I'm writing (to be submitted to the > ApJ). I'm using LaTeX and so need to use encapsulated PostScript for > the figures. The problem is that when the paper is translated to pdf > from PostScript, the mathtext in the figures disappears. The reason > that I think this is a matplotlib issue is that it's never happened to > me with eps figures created in different ways. It's clear that this > must be related to fonts, but I'm not sure how to get around it. Should > I set text.usetex to True? I have a feeling this issue must have come > up before, but I haven't found anything obviously pertinent in the > mailing list archives. > > Jon Are you dead set on using eps files? If the journal doesn't mind, you could always save your figures as pdf files using the pdf backend, then you can use pdflatex on everything and you never have to generate a postscript file. Damon McDougall d.m...@wa... http://damon.is-a-geek.com B2.39 Mathematics Institute Coventry West Midlands CV4 7AL |
From: Jonathan S. <js...@cf...> - 2011-08-16 21:47:17
|
Hi all, I've been making figures for a paper I'm writing (to be submitted to the ApJ). I'm using LaTeX and so need to use encapsulated PostScript for the figures. The problem is that when the paper is translated to pdf from PostScript, the mathtext in the figures disappears. The reason that I think this is a matplotlib issue is that it's never happened to me with eps figures created in different ways. It's clear that this must be related to fonts, but I'm not sure how to get around it. Should I set text.usetex to True? I have a feeling this issue must have come up before, but I haven't found anything obviously pertinent in the mailing list archives. Jon |
From: John H. <jd...@gm...> - 2011-08-16 20:11:13
|
On Mon, Aug 15, 2011 at 9:34 PM, Benjamin Root <ben...@ou...> wrote: > The mpl developers are getting very close to the long-awaited v1.1.0 release > of matplotlib. Before we do so, we are doing some final checking of the > documentation to make sure that all critical pieces of information iss > correct and up to date. > > In checking over the instructions for building and installing matplotlib on > MacOSX, I have found two separate sets of instructions. On the install > page, there is a reference to a README.txt file in "release/osx". This file > is there, but it seems to refer to other files that no longer exists. > Meanwhile, there is an un-referenced file in the top directory called > README.osx that seems a lot more current. > > Because I do not have a Mac that I can use for development, I would like to > ask the community for help in determining the correct set of instructions > and to eliminate cruft. I think it would also be useful to point users to > any relevant instructions for installing/building numpy on Macs. I would > also like to make sure we are current with information on installing on a > stock Lion install. > > Please feel free to respond on this list, or better, make a branch on github > and submit pull requests to help us improve these documents. I wrote both of those files originally (make.osx and releases/osx/*). The original division of labor was the stuff in "releases" was designed to build the release binaries, and the stuff in make.osx was primarily used to build from svn or src. Overtime, most of the effort has gone into make.osx, and it now includes support for binaries. I no longer build the OSX binaries (Russell does) and no longer use OS X (back to ubuntu) so if Russell is not using the stuff in releases/osx, we can flush it. JDH |
From: Ravi K. V. <vvn...@gm...> - 2011-08-16 16:24:46
|
Hi , I wish to add a custom legend to a multicolored line drawn using matplotlib as shown in the figure below http://www.scipy.org/Cookbook/Matplotlib/MulticoloredLine I tried exploring the legend but somehow couldn't figure out its usage and how to adapt it to multicolored line as in the above link I need to use say Red line for label1 and blue line for label2 and green line for label3. All the three colors are a part of a single sinusoidal wave as in the above link. Any thoughts/ideas/suggestions which could provide me some direction on this would be highly appreciated. -- Thanks and Regards, RaviKanth |
From: Andrew M. <and...@gm...> - 2011-08-16 16:22:48
|
I've been trying the Qt4Agg backend for matplotlib and I've encountered two problems. The following code illustrates the issues: import matplotlib matplotlib.use('Qt4Agg') import matplotlib.pyplot as plt plt.ion() plt.plot([1,2,3]) canvas=plt.gcf().canvas def on_key(event): print 'you pressed', event.key, event.xdata, event.ydata canvas.mpl_connect('key_press_event', on_key) The problems: 1) The user has to click within the canvas before key press events are registered. Activating the window is not sufficient. 2) Keys 'up', 'down', 'left', 'right', 'pageup', and 'pagedown' all return event.key=None. The tkagg and gtkagg backends don't have these problems - key press events are active as soon as the window is active, and event.key reports the correct key. Does anyone have an idea why these problems are cropping up with Qt4 or know a workaround? Thanks, -Andrew Mark |
From: Benjamin R. <ben...@ou...> - 2011-08-16 14:46:00
|
On Tue, Aug 16, 2011 at 2:15 AM, 4ndre <and...@gm...> wrote: > > Hi, > > I'm a little bit desperated. I googled for days to find an appropriate way > to calculate the absolute errors of parameters of non-linear fits. I found > different sites which suggest different, sometimes more or less similar > ways. But the results don't make sense. Here is a simple example: > > from pylab import * > from scipy.optimize import curve_fit > def f(x,a,b): > return a*x+b > def fit(n=1000): > x,y=array([0,1,1]),array([1,2,4]) > xf=[(min(x)+i*(max(x)-min(x))/float(n)) for i in range(0,int(n)+1)] > a,acov=curve_fit(f,x,y) > yf=[f(*tuple([i]+list(a))) for i in xf] > meansq=sum([pow(y[i]-f(x[i],a[0],a[1]),2)/(len(x)) for i in > range(0,len(x))]) > redchi2=sum([pow(y[i]-f(x[i],a[0],a[1]),2)/(len(x)-len(a)) for i in > range(0,len(x))]) > print 'standard dev:',sqrt(diag(acov)) > print 'abs. meansq err.:',[acov[i][i]*sqrt(meansq) for i in > range(0,len(a))] > print 'abs. reduced meansq err.:',[acov[i][i]*sqrt(redchi2) for i in > range(0,len(a))] > fit() > > I included 3 ways I found. The used arrays have 3 points, where for x=1 I > give 2 different y values. I would say, > a=2+/-1, b=1+/-0, > but no way yields to a similar result! How can I trust this function on > more > complicated, really non-linear functions? Or is simply this example wrong? > Or are the methods not right? > I'm very thankful for any help! > > Best regards, > André > Andre, Typically, I do something like the following: from scipy.optimize import polyfit, polyval import numpy as np. # x and y are arrays of floats a, b = polyfit(x, y, 1) # first-order polynomial y_fit = polyval([a, b], x) mean_abs_err = np.mean(np.abs(y_fit - y)) I hope that helps! Ben Root |
From: Vlastimil B. <vla...@gm...> - 2011-08-16 10:43:05
|
2011/8/16 Eric Firing <ef...@ha...>: > On 07/25/2011 08:21 AM, Ben Breslauer wrote: >> I think that I have found the problem here. Line2D.draw() (and I >> presume other Artist subclasses) calls >> >> gc.set_foreground(self._color) >> ... >> gc.set_alpha(self._alpha) >> >> self._color is defined by the color kwarg, whether it be a hex value, >> 3-tuple, 4-tuple, or something else. self._alpha is defined by the >> alpha kwarg, but if the alpha kwarg is None, it is not overwritten with >> color[3]. Therefore, using color=(R,G,B,A) does not set alpha >> correctly. I'm not sure the best (i.e. most matplotlib-like) way to >> change this so that the A value gets used iff alpha is None, but I've >> attached a patch that does it one way (diff'ed against the github >> master, commit 67b1cd650f574f9c53ce). I know the patch is less than >> ideal, as it adds kwarg-specific handling into a place where none had >> previously been done, and it's also in a for loop. Maybe it would be >> better to do the checking along with the scalex and scaley pops? > > > Alpha handling is a real can of worms; it has gotten better, but as you > note, there are still problems. Unfortunately, I don't think your > proposed solution will work in general, because self._color could be a > 4-letter string, like "gray", in which case alpha would be set to "y", > and that would not be good at all. I suspect the right place to solve > the problem is down in the GraphicsContext--although I thought I had > already straightened that out some time ago. >... > > Eric > >> >> >> Separately, I noticed that >> backend_bases.GraphicsContextBase.set_foreground claims to only expect >> an RGB definition, and not an RGBA definition. As such, I think that it >> should call >> >> self._rgb = colors.colorConverter.to_rgb(fg) >> >> instead of >> >> self._rgb = colors.colorConverter.to_rgba(fg) >> >> since that will make self._rgb a 3-tuple instead of a 4-tuple. >> >> Ben >> ... >> Just a remark for this recent proposed patch, as I unfortunately don't know the implications for the whole codebase. I believe, that the condition added in the patch if len(line._color) == 4 and line._alpha == None: could be adjusted to e.g.: if isinstance(line._color, tuple) and len(line._color) == 4 and line._alpha == None If the alpha value can be set in the color-tuple (for "#RRGGBBAA" some parsing would be needed, if it is accepted). Possibly the _alpha should be replace with tha alpha value of the colour passed this way like http://matplotlib.sourceforge.net/api/colors_api.html#matplotlib.colors.ColorConverter.to_rgba "If arg is an RGBA sequence and alpha is not None, alpha will replace the original A." But as has been suggested already, it might be better adressed in some more general way, than in this single function. regards, vbr |
From: Damon M. <D.M...@wa...> - 2011-08-16 09:22:23
|
>> Hi Jeff, >> >> I am able to run the tex_demo.py with no problems and I can create >> >> output files using the Agg backend. When I try to use the PDF >> >> backend, however, I get an error which stems from dviread.py (pasted >> >> below). Any thoughts on what could be going wrong? >> >> Thanks! >> >> Jeff >> >> Hi Jeff, >> >> How did you install matplotlib? From source yourself? >> >> No, I'm using the Enthought Python Distribution (EPD64). >> >> And when you installed matplotlib, did it see that you had dvipng installed? >> FYI, you can do >> which dvipng >> to return the path where dvipng lives (if it is in your path already) or you >> can do >> locate dvipng >> to do a search for the binary if it isn't already in your path. >> P.S. You forgot to reply-all so everyone can see your response. > > $ which dvipng > /usr/texbin/dvipng > > I don't remember any complaints while running the EPD installer. > Would there be a way to check this? Is the problem definitely related > to an inability to find dvipng, or could there be other possibilities? > > Thanks, > Jeff I had a similar problem. I don't think it's an inability to find dvipng, I think it's that it couldn't find dvipng when matplotlib was built. When matplotlib builds there'll be a section of text sent to stdout under the heading of 'OPTIONAL DEPENDENCIES', there it will tell you whether it found dvipng when it was building. Are you able to find this? If not, are there install logs saved somewhere after you installed matplotlib? Damon McDougall d.m...@wa... http://damon.is-a-geek.com B2.39 Mathematics Institute Coventry West Midlands CV4 7AL |
From: Till S. <mai...@gm...> - 2011-08-16 09:11:11
|
Hello, for a interactive gui program i want to change the shown data without changing the rest of the figure. For normal plots, there is a set_xdata/set_ydata methods. For QuadMesh, there is a set_array method, which i don't get to work. Thanks, Till |
From: 4ndre <and...@gm...> - 2011-08-16 07:15:51
|
Hi, I'm a little bit desperated. I googled for days to find an appropriate way to calculate the absolute errors of parameters of non-linear fits. I found different sites which suggest different, sometimes more or less similar ways. But the results don't make sense. Here is a simple example: from pylab import * from scipy.optimize import curve_fit def f(x,a,b): return a*x+b def fit(n=1000): x,y=array([0,1,1]),array([1,2,4]) xf=[(min(x)+i*(max(x)-min(x))/float(n)) for i in range(0,int(n)+1)] a,acov=curve_fit(f,x,y) yf=[f(*tuple([i]+list(a))) for i in xf] meansq=sum([pow(y[i]-f(x[i],a[0],a[1]),2)/(len(x)) for i in range(0,len(x))]) redchi2=sum([pow(y[i]-f(x[i],a[0],a[1]),2)/(len(x)-len(a)) for i in range(0,len(x))]) print 'standard dev:',sqrt(diag(acov)) print 'abs. meansq err.:',[acov[i][i]*sqrt(meansq) for i in range(0,len(a))] print 'abs. reduced meansq err.:',[acov[i][i]*sqrt(redchi2) for i in range(0,len(a))] fit() I included 3 ways I found. The used arrays have 3 points, where for x=1 I give 2 different y values. I would say, a=2+/-1, b=1+/-0, but no way yields to a similar result! How can I trust this function on more complicated, really non-linear functions? Or is simply this example wrong? Or are the methods not right? I'm very thankful for any help! Best regards, André -- View this message in context: http://old.nabble.com/absolute-error-of-curve-fit-parameters-tp32269685p32269685.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
From: Andre' Walker-L. <wal...@gm...> - 2011-08-16 06:57:29
|
Hi All, I am trying to create a subplot - where a specific subcell looks like the attached sample_fig.png To make this fig, I did something like ax1 = plt.axes([0.1,0.1,0.65,0.8]) ax2 = plt.axes([0.77,0.1,0.13,0.8]) and then I loaded my data and fit curves onto the separate figs. Now I am trying to create something like this, but where this fig is only one cell of a subplot. But I can't figure this one out, at least not yet, and haven't found a similar enough example. Is there a way to manipulate the equivalent of the axes in a subplot to mimic this figure? Thanks, Andre |
From: Eric F. <ef...@ha...> - 2011-08-16 06:11:08
|
On 07/25/2011 08:21 AM, Ben Breslauer wrote: > I think that I have found the problem here. Line2D.draw() (and I > presume other Artist subclasses) calls > > gc.set_foreground(self._color) > ... > gc.set_alpha(self._alpha) > > self._color is defined by the color kwarg, whether it be a hex value, > 3-tuple, 4-tuple, or something else. self._alpha is defined by the > alpha kwarg, but if the alpha kwarg is None, it is not overwritten with > color[3]. Therefore, using color=(R,G,B,A) does not set alpha > correctly. I'm not sure the best (i.e. most matplotlib-like) way to > change this so that the A value gets used iff alpha is None, but I've > attached a patch that does it one way (diff'ed against the github > master, commit 67b1cd650f574f9c53ce). I know the patch is less than > ideal, as it adds kwarg-specific handling into a place where none had > previously been done, and it's also in a for loop. Maybe it would be > better to do the checking along with the scalex and scaley pops? Alpha handling is a real can of worms; it has gotten better, but as you note, there are still problems. Unfortunately, I don't think your proposed solution will work in general, because self._color could be a 4-letter string, like "gray", in which case alpha would be set to "y", and that would not be good at all. I suspect the right place to solve the problem is down in the GraphicsContext--although I thought I had already straightened that out some time ago. As Ben notes, you should file a bug report. Given that the handling of colors and alpha is inherently tricky (and backend-dependent--ps doesn't support alpha at all), solving the problem well is going to take a bit of time and care, most likely--and testing to make sure that a fix in one place doesn't cause a bug in another. I think we should leave it alone until after the next release. Eric > > > Separately, I noticed that > backend_bases.GraphicsContextBase.set_foreground claims to only expect > an RGB definition, and not an RGBA definition. As such, I think that it > should call > > self._rgb = colors.colorConverter.to_rgb(fg) > > instead of > > self._rgb = colors.colorConverter.to_rgba(fg) > > since that will make self._rgb a 3-tuple instead of a 4-tuple. > > Ben > > On Sat, Jul 23, 2011 at 3:13 PM, Ben Breslauer <bbr...@gm... > <mailto:bbr...@gm...>> wrote: > > Hi, > > I'm trying to fade some data, using alpha values, that I am plotting > with Axes.plot(). I can recreate this problem with 1 line of > pylab.plot. If I use > > pylab.plot([1,2,3],[1,4,9], color=(1,0,0,.2), linewidth=7) > > then I get the equivalent of > > pylab.plot([1,2,3],[1,4,9], color=(1,0,0), linewidth=7) > > i.e. it does not use the alpha value. However, if instead I use > > pylab.plot([1,2,3],[1,4,9], color=(1,0,0), linewidth=7, alpha=.2) > > then the line is faded out appropriately. The plot documentation > indicates that RGBA tuples should be valid, so I'm wondering if this > is a bug. Maybe alpha is defaulting to 1 or None and then not being > overwritten if color is a 4-tuple? > > I'm using Arch Linux with kernel 2.6.39, matplotlib 1.0.1 from the > Arch repo, and the Qt4 backend. My installed Qt version is 4.7.3, > and I am using KDE 4.6.5. Below is verbose-debug output. Thanks > for any help! > > Ben > > > $HOME=/home/ben > CONFIGDIR=/home/ben/.matplotlib > matplotlib data path > /usr/lib/python2.7/site-packages/matplotlib/mpl-data > loaded rc file > /usr/lib/python2.7/site-packages/matplotlib/mpl-data/matplotlibrc > matplotlib version 1.0.1 > verbose.level debug > interactive is False > units is False > platform is linux2 > loaded modules: ['heapq', 'numpy.core.info > <http://numpy.core.info>', 'distutils', 'numpy.lib.format', > 'functools', 'pylab', '_bisect', 'subprocess', 'sysconfig', 'gc', > 'matplotlib.tempfile', 'distutils.sysconfig', 'ctypes._endian', > 'encodings.encodings', 'pyparsing', 'matplotlib.colors', > 'numpy.core.numerictypes', 'numpy.testing.sys', > 'numpy.lib.__future__', 'numpy.fft.types', 'numpy.ma.cPickle', > 'struct', 'numpy.matrixlib.defmatrix', 'numpy.random.info > <http://numpy.random.info>', 'tempfile', 'numpy.compat.types', > 'pprint', 'numpy.linalg', 'matplotlib.threading', > 'numpy.core.machar', 'numpy.testing.types', 'numpy.testing', > 'collections', 'numpy.polynomial.sys', 'unittest.sys', > 'numpy.core.umath', 'unittest.main', 'distutils.types', > 'numpy.testing.operator', 'numpy.core.scalarmath', 'numpy.ma.sys', > 'zipimport', 'string', 'matplotlib.subprocess', 'numpy.testing.os', > 'unittest.functools', 'numpy.lib.arraysetops', > 'numpy.testing.unittest', 'numpy.lib.math', 'encodings.utf_8', > 'matplotlib.__future__', 'unittest.types', 'unittest.util', > 'numpy.testing.re <http://numpy.testing.re>', 'numpy.version', > 'numpy.lib.re <http://numpy.lib.re>', 'distutils.re > <http://distutils.re>', 'numpy.matrixlib.sys', 'ctypes.os', > 'numpy.core.os', 'numpy.lib.type_check', 'numpy.compat.sys', > 'unittest.StringIO', 'bisect', 'numpy.core._internal', 'signal', > 'numpy.lib.types', 'numpy.lib._datasource', 'random', > 'numpy.lib.__builtin__', 'numpy.fft.fftpack_lite', > 'matplotlib.cbook', 'textwrap', 'numpy.core.multiarray', > 'numpy.polynomial.string', 'distutils.version', 'cStringIO', > 'numpy.polynomial', 'numpy.numpy', 'matplotlib.StringIO', > 'unittest.time', 'locale', 'numpy.add_newdocs', 'unittest.difflib', > 'numpy.core.getlimits', 'base64', '_ssl', 'numpy.lib.sys', > 'encodings', 'numpy.ma.itertools', 'unittest.pprint', 'unittest.re > <http://unittest.re>', 'abc', 'numpy.matrixlib', 'numpy.ctypes', > 'numpy.testing.decorators', 'matplotlib.warnings', 'rfc822', > 'numpy.lib.npyio', 'numpy.lib.numpy', 'matplotlib.sys', 're', > 'numpy.lib._compiled_base', 'numpy.polynomial.legendre', > 'threading', 'new', 'numpy.ma.warnings', 'numpy.random.mtrand', > 'urllib2', 'matplotlib.cPickle', 'math', 'numpy.fft.helper', > 'fcntl', 'unittest.case', 'matplotlib.numpy', 'UserDict', > 'unittest.suite', 'numpy.lib.function_base', 'distutils.os', > 'matplotlib', 'numpy.fft.numpy', 'exceptions', 'numpy.lib.info > <http://numpy.lib.info>', 'ctypes', 'numpy.lib.warnings', > 'ctypes.struct', 'codecs', 'numpy.core._sort', 'numpy.os', > 'unittest.loader', '_functools', '_locale', 'numpy.__builtin__', > 'matplotlib.os', 'thread', 'StringIO', 'numpy.core.memmap', > 'traceback', 'numpy.testing.warnings', 'weakref', 'itertools', > 'numpy.fft.fftpack', 'numpy.linalg.lapack_lite', 'numpy.ma > <http://numpy.ma>', 'distutils.sys', 'os', 'marshal', > 'numpy.lib.itertools', '__future__', '_collections', 'urllib', > 'matplotlib.traceback', '_sre', 'unittest', 'numpy.core.sys', > 'numpy.random', 'numpy.linalg.numpy', '__builtin__', > 'numpy.lib.twodim_base', 'numpy.ma.core', 'matplotlib.re > <http://matplotlib.re>', 'numpy.core.cPickle', 'unittest.runner', > 'operator', 'numpy.polynomial.polytemplate', > 'numpy.core.arrayprint', 'distutils.string', > 'numpy.lib.arrayterator', 'select', 'ctypes._ctypes', '_heapq', > 'ctypes.sys', 'matplotlib.errno', 'unittest.collections', > 'posixpath', 'numpy.lib.financial', 'numpy.polynomial.laguerre', > 'matplotlib.random', 'errno', '_socket', 'binascii', > 'sre_constants', 'datetime', 'numpy.core.shape_base', 'os.path', > 'numpy.core.function_base', 'numpy.compat.py3k', > 'numpy.lib.stride_tricks', 'numpy.core.numpy', 'numpy', '_warnings', > 'numpy.polynomial.chebyshev', 'matplotlib.types', 'cPickle', > 'encodings.__builtin__', 'numpy.polynomial.warnings', > 'matplotlib.new', '_codecs', 'numpy.lib.operator', > 'unittest.fnmatch', 'numpy.polynomial.polynomial', > 'numpy.__config__', 'pwd', 'matplotlib.pyparsing', 'httplib', > 'numpy.lib.ufunclike', 'copy', 'numpy.core.re > <http://numpy.core.re>', '_struct', 'numpy.core.fromnumeric', > 'hashlib', 'numpy.ctypeslib', 'keyword', 'array', > 'numpy.lib.scimath', 'numpy.fft', 'numpy.lib', 'numpy.ma.numpy', > 'numpy.random.numpy', 'matplotlib.urllib2', 'unittest.weakref', > 'numpy.ma.extras', 'numpy.polynomial.__future__', 'posix', > 'encodings.aliases', 'matplotlib.fontconfig_pattern', 'fnmatch', > 'sre_parse', 'pickle', 'numpy.core.ctypes', 'mimetools', > 'distutils.distutils', 'unittest.signal', 'copy_reg', 'sre_compile', > '_hashlib', '_random', '_ctypes', 'site', 'numpy.lib.polynomial', > 'numpy.compat', 'numpy._import_tools', 'numpy.polynomial.hermite', > '__main__', 'numpy.fft.info <http://numpy.fft.info>', > 'numpy.core.records', 'shutil', 'numpy.lib.cPickle', 'numpy.sys', > 'numpy.polynomial.hermite_e', 'urlparse', 'unittest.result', > 'strop', 'grp', 'linecache', 'numpy.polynomial.numpy', > 'numpy.core.numeric', 'numpy.linalg.info > <http://numpy.linalg.info>', 'encodings.codecs', '_abcoll', > 'numpy.core', 'matplotlib.locale', 'matplotlib.rcsetup', > 'matplotlib.time', 'matplotlib.weakref', 'genericpath', 'stat', > 'socket', 'numpy.lib._iotools', 'numpy.lib.index_tricks', > 'numpy.testing.utils', 'warnings', 'numpy.lib.utils', > 'numpy.core.defchararray', 'numpy.polynomial.polyutils', > 'numpy.lib.shape_base', 'numpy.core.types', 'unittest.signals', > 'sys', 'numpy.core.warnings', 'numpy.compat._inspect', > 'numpy.core.__builtin__', 'ctypes.ctypes', > 'numpy.testing.traceback', 'numpy.lib.os', > 'numpy.testing.nosetester', 'types', 'numpy.lib.shutil', > 'matplotlib.datetime', 'matplotlib.distutils', '_weakref', > 'numpy.testing.numpytest', 'difflib', 'distutils.errors', > 'numpy.matrixlib.numpy', 'matplotlib.matplotlib', '_weakrefset', > 'matplotlib.shutil', 'numpy.lib.cStringIO', 'unittest.warnings', > 'time', 'unittest.traceback', 'ssl', 'numpy.linalg.linalg', > 'unittest.os', 'numpy.testing.numpy'] > Using fontManager instance from /home/ben/.matplotlib/fontList.cache > backend Qt4Agg version 0.9.1 > findfont: Matching > :family=sans-serif:style=normal:variant=normal:weight=normal:stretch=normal:size=medium > to Bitstream Vera Sans > (/usr/lib/python2.7/site-packages/matplotlib/mpl-data/fonts/ttf/Vera.ttf) > with score of 0.000000 > > > > > ------------------------------------------------------------------------------ > Storage Efficiency Calculator > This modeling tool is based on patent-pending intellectual property that > has been used successfully in hundreds of IBM storage optimization engage- > ments, worldwide. Store less, Store more with what you own, Move data to > the right place. Try It Now! http://www.accelacomm.com/jaw/sfnl/114/51427378/ > > > > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users |
From: Benjamin R. <ben...@ou...> - 2011-08-16 04:27:53
|
On Monday, August 15, 2011, Ben Breslauer <bbr...@gm...> wrote: > Hi, > > Has anyone else noticed this behavior? For the devs, do you prefer a github bug to the SF list? > > Ben I have not personally observed this, but usually, people don't specify rgba tuples for plot. I think the lack of response is due to our focus on larger bugs right now for the upcoming release. Therefore, it would probably be best to file a bug report with your patch so that we have a record of it. The fuller patch might be more involved (consider scatter and other functions). Plus, we would likely need to consider what to do if both an rgba tuple and alpha were specified, As a rule of thumb, if we don't respond on list, file a bug report. Thanks for bringing this to our attention! Ben Root |
From: Ben B. <bbr...@gm...> - 2011-08-16 03:08:50
|
Hi, Has anyone else noticed this behavior? For the devs, do you prefer a github bug to the SF list? Ben On Mon, Jul 25, 2011 at 2:21 PM, Ben Breslauer <bbr...@gm...> wrote: > I think that I have found the problem here. Line2D.draw() (and I presume > other Artist subclasses) calls > > gc.set_foreground(self._color) > ... > gc.set_alpha(self._alpha) > > self._color is defined by the color kwarg, whether it be a hex value, > 3-tuple, 4-tuple, or something else. self._alpha is defined by the alpha > kwarg, but if the alpha kwarg is None, it is not overwritten with color[3]. > Therefore, using color=(R,G,B,A) does not set alpha correctly. I'm not sure > the best (i.e. most matplotlib-like) way to change this so that the A value > gets used iff alpha is None, but I've attached a patch that does it one way > (diff'ed against the github master, commit 67b1cd650f574f9c53ce). I know > the patch is less than ideal, as it adds kwarg-specific handling into a > place where none had previously been done, and it's also in a for loop. > Maybe it would be better to do the checking along with the scalex and scaley > pops? > > > Separately, I noticed that backend_bases.GraphicsContextBase.set_foreground > claims to only expect an RGB definition, and not an RGBA definition. As > such, I think that it should call > > self._rgb = colors.colorConverter.to_rgb(fg) > > instead of > > self._rgb = colors.colorConverter.to_rgba(fg) > > since that will make self._rgb a 3-tuple instead of a 4-tuple. > > Ben > > > On Sat, Jul 23, 2011 at 3:13 PM, Ben Breslauer <bbr...@gm...>wrote: > >> Hi, >> >> I'm trying to fade some data, using alpha values, that I am plotting with >> Axes.plot(). I can recreate this problem with 1 line of pylab.plot. If I >> use >> >> pylab.plot([1,2,3],[1,4,9], color=(1,0,0,.2), linewidth=7) >> >> then I get the equivalent of >> >> pylab.plot([1,2,3],[1,4,9], color=(1,0,0), linewidth=7) >> >> i.e. it does not use the alpha value. However, if instead I use >> >> pylab.plot([1,2,3],[1,4,9], color=(1,0,0), linewidth=7, alpha=.2) >> >> then the line is faded out appropriately. The plot documentation >> indicates that RGBA tuples should be valid, so I'm wondering if this is a >> bug. Maybe alpha is defaulting to 1 or None and then not being overwritten >> if color is a 4-tuple? >> >> I'm using Arch Linux with kernel 2.6.39, matplotlib 1.0.1 from the Arch >> repo, and the Qt4 backend. My installed Qt version is 4.7.3, and I am using >> KDE 4.6.5. Below is verbose-debug output. Thanks for any help! >> >> Ben >> >> >> $HOME=/home/ben >> CONFIGDIR=/home/ben/.matplotlib >> matplotlib data path /usr/lib/python2.7/site-packages/matplotlib/mpl-data >> loaded rc file >> /usr/lib/python2.7/site-packages/matplotlib/mpl-data/matplotlibrc >> matplotlib version 1.0.1 >> verbose.level debug >> interactive is False >> units is False >> platform is linux2 >> loaded modules: ['heapq', 'numpy.core.info', 'distutils', >> 'numpy.lib.format', 'functools', 'pylab', '_bisect', 'subprocess', >> 'sysconfig', 'gc', 'matplotlib.tempfile', 'distutils.sysconfig', >> 'ctypes._endian', 'encodings.encodings', 'pyparsing', 'matplotlib.colors', >> 'numpy.core.numerictypes', 'numpy.testing.sys', 'numpy.lib.__future__', >> 'numpy.fft.types', 'numpy.ma.cPickle', 'struct', >> 'numpy.matrixlib.defmatrix', 'numpy.random.info', 'tempfile', >> 'numpy.compat.types', 'pprint', 'numpy.linalg', 'matplotlib.threading', >> 'numpy.core.machar', 'numpy.testing.types', 'numpy.testing', 'collections', >> 'numpy.polynomial.sys', 'unittest.sys', 'numpy.core.umath', 'unittest.main', >> 'distutils.types', 'numpy.testing.operator', 'numpy.core.scalarmath', >> 'numpy.ma.sys', 'zipimport', 'string', 'matplotlib.subprocess', >> 'numpy.testing.os', 'unittest.functools', 'numpy.lib.arraysetops', >> 'numpy.testing.unittest', 'numpy.lib.math', 'encodings.utf_8', >> 'matplotlib.__future__', 'unittest.types', 'unittest.util', ' >> numpy.testing.re', 'numpy.version', 'numpy.lib.re', 'distutils.re', >> 'numpy.matrixlib.sys', 'ctypes.os', 'numpy.core.os', 'numpy.lib.type_check', >> 'numpy.compat.sys', 'unittest.StringIO', 'bisect', 'numpy.core._internal', >> 'signal', 'numpy.lib.types', 'numpy.lib._datasource', 'random', >> 'numpy.lib.__builtin__', 'numpy.fft.fftpack_lite', 'matplotlib.cbook', >> 'textwrap', 'numpy.core.multiarray', 'numpy.polynomial.string', >> 'distutils.version', 'cStringIO', 'numpy.polynomial', 'numpy.numpy', >> 'matplotlib.StringIO', 'unittest.time', 'locale', 'numpy.add_newdocs', >> 'unittest.difflib', 'numpy.core.getlimits', 'base64', '_ssl', >> 'numpy.lib.sys', 'encodings', 'numpy.ma.itertools', 'unittest.pprint', ' >> unittest.re', 'abc', 'numpy.matrixlib', 'numpy.ctypes', >> 'numpy.testing.decorators', 'matplotlib.warnings', 'rfc822', >> 'numpy.lib.npyio', 'numpy.lib.numpy', 'matplotlib.sys', 're', >> 'numpy.lib._compiled_base', 'numpy.polynomial.legendre', 'threading', 'new', >> 'numpy.ma.warnings', 'numpy.random.mtrand', 'urllib2', 'matplotlib.cPickle', >> 'math', 'numpy.fft.helper', 'fcntl', 'unittest.case', 'matplotlib.numpy', >> 'UserDict', 'unittest.suite', 'numpy.lib.function_base', 'distutils.os', >> 'matplotlib', 'numpy.fft.numpy', 'exceptions', 'numpy.lib.info', >> 'ctypes', 'numpy.lib.warnings', 'ctypes.struct', 'codecs', >> 'numpy.core._sort', 'numpy.os', 'unittest.loader', '_functools', '_locale', >> 'numpy.__builtin__', 'matplotlib.os', 'thread', 'StringIO', >> 'numpy.core.memmap', 'traceback', 'numpy.testing.warnings', 'weakref', >> 'itertools', 'numpy.fft.fftpack', 'numpy.linalg.lapack_lite', 'numpy.ma', >> 'distutils.sys', 'os', 'marshal', 'numpy.lib.itertools', '__future__', >> '_collections', 'urllib', 'matplotlib.traceback', '_sre', 'unittest', >> 'numpy.core.sys', 'numpy.random', 'numpy.linalg.numpy', '__builtin__', >> 'numpy.lib.twodim_base', 'numpy.ma.core', 'matplotlib.re', >> 'numpy.core.cPickle', 'unittest.runner', 'operator', >> 'numpy.polynomial.polytemplate', 'numpy.core.arrayprint', >> 'distutils.string', 'numpy.lib.arrayterator', 'select', 'ctypes._ctypes', >> '_heapq', 'ctypes.sys', 'matplotlib.errno', 'unittest.collections', >> 'posixpath', 'numpy.lib.financial', 'numpy.polynomial.laguerre', >> 'matplotlib.random', 'errno', '_socket', 'binascii', 'sre_constants', >> 'datetime', 'numpy.core.shape_base', 'os.path', 'numpy.core.function_base', >> 'numpy.compat.py3k', 'numpy.lib.stride_tricks', 'numpy.core.numpy', 'numpy', >> '_warnings', 'numpy.polynomial.chebyshev', 'matplotlib.types', 'cPickle', >> 'encodings.__builtin__', 'numpy.polynomial.warnings', 'matplotlib.new', >> '_codecs', 'numpy.lib.operator', 'unittest.fnmatch', >> 'numpy.polynomial.polynomial', 'numpy.__config__', 'pwd', >> 'matplotlib.pyparsing', 'httplib', 'numpy.lib.ufunclike', 'copy', ' >> numpy.core.re', '_struct', 'numpy.core.fromnumeric', 'hashlib', >> 'numpy.ctypeslib', 'keyword', 'array', 'numpy.lib.scimath', 'numpy.fft', >> 'numpy.lib', 'numpy.ma.numpy', 'numpy.random.numpy', 'matplotlib.urllib2', >> 'unittest.weakref', 'numpy.ma.extras', 'numpy.polynomial.__future__', >> 'posix', 'encodings.aliases', 'matplotlib.fontconfig_pattern', 'fnmatch', >> 'sre_parse', 'pickle', 'numpy.core.ctypes', 'mimetools', >> 'distutils.distutils', 'unittest.signal', 'copy_reg', 'sre_compile', >> '_hashlib', '_random', '_ctypes', 'site', 'numpy.lib.polynomial', >> 'numpy.compat', 'numpy._import_tools', 'numpy.polynomial.hermite', >> '__main__', 'numpy.fft.info', 'numpy.core.records', 'shutil', >> 'numpy.lib.cPickle', 'numpy.sys', 'numpy.polynomial.hermite_e', 'urlparse', >> 'unittest.result', 'strop', 'grp', 'linecache', 'numpy.polynomial.numpy', >> 'numpy.core.numeric', 'numpy.linalg.info', 'encodings.codecs', '_abcoll', >> 'numpy.core', 'matplotlib.locale', 'matplotlib.rcsetup', 'matplotlib.time', >> 'matplotlib.weakref', 'genericpath', 'stat', 'socket', 'numpy.lib._iotools', >> 'numpy.lib.index_tricks', 'numpy.testing.utils', 'warnings', >> 'numpy.lib.utils', 'numpy.core.defchararray', 'numpy.polynomial.polyutils', >> 'numpy.lib.shape_base', 'numpy.core.types', 'unittest.signals', 'sys', >> 'numpy.core.warnings', 'numpy.compat._inspect', 'numpy.core.__builtin__', >> 'ctypes.ctypes', 'numpy.testing.traceback', 'numpy.lib.os', >> 'numpy.testing.nosetester', 'types', 'numpy.lib.shutil', >> 'matplotlib.datetime', 'matplotlib.distutils', '_weakref', >> 'numpy.testing.numpytest', 'difflib', 'distutils.errors', >> 'numpy.matrixlib.numpy', 'matplotlib.matplotlib', '_weakrefset', >> 'matplotlib.shutil', 'numpy.lib.cStringIO', 'unittest.warnings', 'time', >> 'unittest.traceback', 'ssl', 'numpy.linalg.linalg', 'unittest.os', >> 'numpy.testing.numpy'] >> Using fontManager instance from /home/ben/.matplotlib/fontList.cache >> backend Qt4Agg version 0.9.1 >> findfont: Matching >> :family=sans-serif:style=normal:variant=normal:weight=normal:stretch=normal:size=medium >> to Bitstream Vera Sans >> (/usr/lib/python2.7/site-packages/matplotlib/mpl-data/fonts/ttf/Vera.ttf) >> with score of 0.000000 >> >> > |
From: gorge <roh...@gm...> - 2011-08-16 03:03:20
|
Is there some way to determine the corresponding y coordinate of a shape (the edge of a circle for example) given an x coordinate of that shape? I know that for a circle there would be to 2 coordinates for each x coordinate, but I'm not actually plotting a whole circle, only a quarter of a circle. Which brings me to me 2nd quest of how you plot a quarter of a circle with radius of length of 1 onto an a canvas. -- View this message in context: http://old.nabble.com/finding-the-y-coordinate-at-a-particular-x-coordinate-tp32268951p32268951.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
From: Benjamin R. <ben...@ou...> - 2011-08-16 02:34:27
|
The mpl developers are getting very close to the long-awaited v1.1.0 release of matplotlib. Before we do so, we are doing some final checking of the documentation to make sure that all critical pieces of information iss correct and up to date. In checking over the instructions for building and installing matplotlib on MacOSX, I have found two separate sets of instructions. On the install page, there is a reference to a README.txt file in "release/osx". This file is there, but it seems to refer to other files that no longer exists. Meanwhile, there is an un-referenced file in the top directory called README.osx that seems a lot more current. Because I do not have a Mac that I can use for development, I would like to ask the community for help in determining the correct set of instructions and to eliminate cruft. I think it would also be useful to point users to any relevant instructions for installing/building numpy on Macs. I would also like to make sure we are current with information on installing on a stock Lion install. Please feel free to respond on this list, or better, make a branch on github and submit pull requests to help us improve these documents. Thanks! Ben Root |
From: Vlastimil B. <vla...@gm...> - 2011-08-16 00:58:43
|
2011/8/15 Michael Droettboom <md...@st...>: > On 08/14/2011 11:28 AM, Vlastimil Brom wrote: >> ... >> Is there maybe some mechanism available in matplotlib, which would >> select the appropriate font for the given characters? (Like in wx or, >> even more powerful in tk?) Or is it the expected way to set the >> suitable font individually, as only the font list in rcParams are >> tried sequentially - regardless of the character support? > That's correct: matplotlib doesn't currently do this. It renders a > particular string of text with a single font and does not do font > substitution for characters that are not in that font. The best > practice is to use a font that contains the full set of characters, such > as Arial or Deja Vu as you've discovered. > > There a lot of other i18n shortcomings to the way matplotlib supports > text (such as a lack of bidi support). That's a large wheel to > reinvent, so the solution would involve using a third-party text layout > library such as pango, but I know there is licensing friction against > that. It may be worth revisiting that at some point. > > Mike > > Thanks for the confirmation, I'll stick with this apporoach, as I didn't manage to fix the code for wx backend on the newest version (cf. above). Given the status of the non-Agg backends it might be more appropriate. Regards, vbr |
From: Jeff K. <kl...@wi...> - 2011-08-15 22:14:56
|
On Mon, Aug 15, 2011 at 10:00 PM, Damon McDougall <D.M...@wa...> wrote: > Hi Jeff, > > I am able to run the tex_demo.py with no problems and I can create > > output files using the Agg backend. When I try to use the PDF > > backend, however, I get an error which stems from dviread.py (pasted > > below). Any thoughts on what could be going wrong? > > Thanks! > > Jeff > > Hi Jeff, > > How did you install matplotlib? From source yourself? > > No, I'm using the Enthought Python Distribution (EPD64). > > And when you installed matplotlib, did it see that you had dvipng installed? > FYI, you can do > which dvipng > to return the path where dvipng lives (if it is in your path already) or you > can do > locate dvipng > to do a search for the binary if it isn't already in your path. > P.S. You forgot to reply-all so everyone can see your response. $ which dvipng /usr/texbin/dvipng I don't remember any complaints while running the EPD installer. Would there be a way to check this? Is the problem definitely related to an inability to find dvipng, or could there be other possibilities? Thanks, Jeff |
From: Paradoxdruid <bo...@gm...> - 2011-08-15 22:14:29
|
I just wanted to add that I'm getting the exact same error. On a fresh, new iMac running 10.6.8, I installed ActivePython 2.6, along with matplotlib for 2.6 on OSX. Running example code from the matplotlib website, I get the same error-- the window appears with the resizing tools but otherwise blank, and the program throws the listed Tcl error. Any ideas? Thank you for your help, Andrew Nate Gallagher wrote: > > Please help. > -Nate > > > ----- Forwarded Message ---- >> From: Nate Gallagher <nat...@ya...> >> To: mat...@li... >> Sent: Mon, March 28, 2011 2:41:39 PM >> Subject: [Matplotlib-users] Plot show() errors, Mac OS 10.6 >> >> operating system >> $ uname -a >> Darwin nate-gallaghers-macbook-pro.local 10.6.0 Darwin Kernel Version >> 10.6.0: > >> Wed Nov 10 18:13:17 PST 2010; root:xnu-1504.9.26~3/RELEASE_I386 i386 >> >> matplotlib version: >> matplotlib-1.0.1-python.org-32bit-py2.7-macosx10.3.dmg >> >> obtained from: >> http://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-1.0.1/ >> >> no o customizations to matplotlibrc >> >> $ python simple_plot.py --verbose-helpful >> >> $HOME=/Users/ibook >> CONFIGDIR=/Users/ibook/.matplotlib >> matplotlib data path >>/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/mpl-data >>a >> >> loaded rc file >>/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/mpl-data/matplotlibrc >>c >> >> matplotlib version 1.0.1 >> verbose.level helpful >> interactive is False >> units is False >> platform is darwin >> Using fontManager instance from /Users/ibook/.matplotlib/fontList.cache >> backend TkAgg version 8.5 >> findfont: Matching >>:family=sans-serif:style=normal:variant=normal:weight=normal:stretch=normal:size=medium >>m >> to Bitstream Vera Sans >>(/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/mpl-data/fonts/ttf/Vera.ttf) >>) >> with score of 0.000000 >> Exception in Tkinter callback >> Traceback (most recent call last): >> File >>"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-tk/Tkinter.py", >>, >> line 1410, in __call__ >> return self.func(*args) >> File >>"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/backends/backend_tkagg.py", >>, >> line 245, in resize >> self.show() >> File >>"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/backends/backend_tkagg.py", >>, >> line 249, in draw >> tkagg.blit(self._tkphoto, self.renderer._renderer, colormode=2) >> File >>"/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/backends/tkagg.py", >>, >> line 19, in blit >> tk.call("PyAggImagePhoto", photoimage, id(aggimage), colormode, >> id(bbox_array)) >> TclError >> >> ------------------------------------------------------------------------------ >> Create and publish websites with WebMatrix >> Use the most popular FREE web apps or write code yourself; >> WebMatrix provides all the features you need to develop and publish >> your website. http://p.sf.net/sfu/ms-webmatrix-sf >> _______________________________________________ >> Matplotlib-users mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >> > > ------------------------------------------------------------------------------ > Create and publish websites with WebMatrix > Use the most popular FREE web apps or write code yourself; > WebMatrix provides all the features you need to develop and > publish your website. http://p.sf.net/sfu/ms-webmatrix-sf > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > -- View this message in context: http://old.nabble.com/Window-appears%2C-no-graph-drawn-Fw%3A--Plot-show%28%29-errors%2C-Mac-OS-10.6-tp31279007p32267934.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
From: Damon M. <D.M...@wa...> - 2011-08-15 22:00:41
|
>> Hi Jeff, >> >> I am able to run the tex_demo.py with no problems and I can create >> output files using the Agg backend. When I try to use the PDF >> backend, however, I get an error which stems from dviread.py (pasted >> below). Any thoughts on what could be going wrong? >> >> Thanks! >> Jeff >> >> Hi Jeff, >> How did you install matplotlib? From source yourself? > > No, I'm using the Enthought Python Distribution (EPD64). And when you installed matplotlib, did it see that you had dvipng installed? FYI, you can do which dvipng to return the path where dvipng lives (if it is in your path already) or you can do locate dvipng to do a search for the binary if it isn't already in your path. P.S. You forgot to reply-all so everyone can see your response. Damon McDougall d.m...@wa... http://damon.is-a-geek.com B2.39 Mathematics Institute Coventry West Midlands CV4 7AL |