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
(7) |
2
(12) |
3
(7) |
4
(23) |
5
(5) |
6
(7) |
7
(4) |
|
8
(7) |
9
(25) |
10
(17) |
11
(25) |
12
(11) |
13
(8) |
14
(6) |
|
15
(1) |
16
(22) |
17
(11) |
18
(12) |
19
(22) |
20
(32) |
21
(9) |
|
22
(4) |
23
(16) |
24
(5) |
25
(9) |
26
(26) |
27
(21) |
28
(14) |
|
29
(6) |
30
(8) |
31
(4) |
|
|
|
|
|
From: stetrick <sco...@gm...> - 2010-08-09 22:09:12
|
I am now getting a message that says: Fatal Python error: PyEval_RestoreThread: NULL tstate This application has requested the Runtime to terminate it in an unusual way. This is with matplotlib 1.0.0, but all versions are 64-bit (python, numpy, matplotlib). Is this something I can fix or ignore? Thanks! -- View this message in context: http://old.nabble.com/Fatal-Python-Error-with-64-bit-versions-tp29392620p29392620.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: Friedrich R. <fri...@gm...> - 2010-08-09 21:45:33
|
2010/8/9 Antonino Cucchiara <acu...@lb...>: > Hello, > I recently upgraded to Enthought python 2.6 an so I have now matplotlib > 0.99.3 > My scripts now no longer seem to find the pyGTK since when I run them I got > this message: > > [...] Where was your original pygtk installed, and what was your previous Python version (and installation location, if you can provide)? I think pygtk is compiled against Python, so it cannot be simply copied over. How did you install pyGTK before? Friedrich |
|
From: Friedrich R. <fri...@gm...> - 2010-08-09 21:36:46
|
2010/8/8 Rob Schneider <rm...@rm...>: > Running 0.98.5.3 > (would upgrade to 1.0 but having trouble installing it on Mac OS X as it doesn't appear to like the version of Python Apple provides). What's your problem with 1.0? Friedrich |
|
From: Friedrich R. <fri...@gm...> - 2010-08-09 21:34:24
|
2010/8/9 Markus Baden <mar...@gm...>: > On my Macbook Pro I use Python 2.6 as provided by the Enthought Python > Distribution. I ran into some problem with Axes3D so I decided to > upgrade to the latest version from source. While trying that I got a > similiar error message as discussed in > > http://www.mail-archive.com/mat...@li.../msg12938.html > > i.e. error: png.h: No such file or directory > > In short matplotlib could not find libpng (or png.h from that). I had > libpng installed via fink in the usual place /sw/include etc. This > seems to be a quite natural choice, so I wondered why matplotlib does > not find that out of the box. Following the tips in the above post I > looked at basedir in setupext.py For some reason the basedirs for > darwin where commented out. Uncommenting the basedirs did the trick > for me [1] and matplotlib happily installed with the libpng from fink. > > Hope this will help other mac users. Thanks for the great work on > matplotlib! Thanks for reporting finally a working pure-setup.py installation! But are you sure it really works, because mixing binary-distributed and self-compiled packages often leads to import refusal, when the external libraries (as freetype) are compiled with a different compiler than Python. Friedrich |
|
From: Friedrich R. <fri...@gm...> - 2010-08-09 21:21:32
|
2010/8/9 Wayne Watson <sie...@sb...>: > See Subject. I use matplotlib, scipy, numpy and possibly one other > module. If I go to the control panel, I only see numpy listed. Why? I > use a search and find only numpy and Python itself. How can matplotlib > and scipy be uninstalled? I think it should suffice to delete the: - matplotlib - mpl_toolkits - and scipy (for scipy I don't know if there are more packages) directories from C:\Python\Lib\site-packages. There is no more the uninstaller can do. Sometimes the packages also place a RemoveXXX.exe in the Python toplevel directory, but since it doesn't show up in the registry, I think this will not work. When your registry is clean, if I really would like to finally get "rid" of it, I would delete if it were my own machine. But I also would not like to "uninstall", but rather "hide", i.e., you can rename it to some sensible name, e.g. matplotlib -> matplotlib-10-08-09. Then you can reinstall the library with another version without interference, and the files are not lost until the installation is working finally. Finally, there may be some matplotlib-blahblahblah.egg-info and scipy-foobar.egg-info files in site-packages, where I don't know what they do precisely. They are just plain text files, containing meta-data about the package installed. Friedrich |
|
From: Michael H. <jm_...@ya...> - 2010-08-09 20:01:39
|
----- Original Message ----
> From: Michael Droettboom <md...@st...>
> To: Michael Hannon <jm_...@ya...>;
>mat...@li...
> Sent: Thu, August 5, 2010 6:24:58 AM
> Subject: Re: [Matplotlib-users] Problem getting math symbols into text
> It looks like you're configured for the STIX fonts (the rcParam
> mathtext.fontset = stix), but they are not installed on your system.
>
> Do you have the file "STIXGeneral.ttf" on your system? Perhaps you need to
> install an additional package.
Hi, Mike. I've thrashed around a bit more with this. It appears that if I
use the matplotlib from Fedora 13 (version 0.99) I get the correct behavior
for math text if I also install the stix* packages AND set
rcParams[mathtext.fontset] to "stix". (There are four stix packages in Fedora
13, all small, and I just installed all of them, so I don't know what the
minimum requirement is).
I also got the appropriate math text when I installed the latest matplotlib
from source and used all the default settings. I've now reverted to the
standard Fedora packages and stix, so I can't easily compare the two sets of
rcParams.
Thanks for your help.
-- Mike
|
|
From: Fernando P. <fpe...@gm...> - 2010-08-09 18:57:18
|
On Mon, Aug 9, 2010 at 11:49 AM, Filipe Pires Alvarenga Fernandes <oc...@gm...> wrote: > > It sacrifice a more fine control, but simplify the processes for the > majority of the plots that I produce. Yes, that was the idea. We figured that if you need very fine-grained control over axis sharing in complex ways, you're probably OK using the manual API. But for the vast majority of users this seemed like a decent solution. It could in the long run be extended to allow passing of a list of axis indices to activate sharing for x/y on, though. Patches welcome :) Cheers, f |
|
From: Filipe P. A. F. <oc...@gm...> - 2010-08-09 18:50:27
|
On Mon, Aug 9, 2010 at 12:22, Fernando Perez <fpe...@gm...> wrote: > On Mon, Aug 9, 2010 at 8:48 AM, Filipe Fernandes <oc...@gm...> wrote: >> >> The docstring for sunplots has the "sharex(y) option", but my "ax" are >> being created now!? Is that a chicken and egg problem? Or I'm failing to >> understand the logic here. > > Don't worry: when you indicate that you want to share axes (x or y), > subplots() tracks that and enables it as it creates the axis objects. > Give it a try and see if it works :) > > Cheers, > > f > Great, just now I realized that the option is sharex(y)=True/False and no longer sharex=ax1. It sacrifice a more fine control, but simplify the processes for the majority of the plots that I produce. Thanks! |
|
From: Filipe F. <oc...@gm...> - 2010-08-09 18:42:00
|
Hello list, Some time ago Stephane Raynaud answered my question on how to produce a stickplot using quiver: http://www.mail-archive.com/mat...@li.../msg15314.html Since then, I have been forwarding that to several people interested in producing such a plot. Maybe it is a good idea to add an example at the Gallery with the quiver as "stickplot"? Or it is too obvious? Anyway, here is my suggestion: # -*- coding: utf-8 -*- """ Stephane Raynaud """ import matplotlib.pyplot as plt import numpy as np import datetime as dtime from matplotlib.dates import date2num """ fake dates starting now """ x = np.arange(100, 110, 0.1) start = dtime.datetime.now() dates = [start + dtime.timedelta(days=n) for n in range(len(x))] """ dummy u, v """ u = np.sin(x) v = np.cos(x) fig, ax = plt.subplots(1, 1, figsize=(16,6)) qiv = ax.quiver(date2num(dates), [[0]*len(x)], u, v, headlength=0, headwidth=0, headaxislength=0 ) key = ax.quiverkey(qiv, 0.25, 0.75, 0.5, "0.5 N m$^{-2}$", labelpos='N', coordinates='axes' ) plt.setp( ax.get_yticklabels(), visible=False) plt.gca().xaxis_date() plt.show() |
|
From: Antonino C. <acu...@lb...> - 2010-08-09 16:28:00
|
Hello,
I recently upgraded to Enthought python 2.6 an so I have now matplotlib
0.99.3
My scripts now no longer seem to find the pyGTK since when I run them I
got this message:
Traceback (most recent call last):
File "./sed_plotb_v2.py", line 14, in <module>
from pylab import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/pylab.py",
line 1, in <module>
from matplotlib.pylab import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/pylab.py",
line 247, in <module>
from matplotlib.pyplot import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/pyplot.py",
line 78, in <module>
new_figure_manager, draw_if_interactive, show = pylab_setup()
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/__init__.py",
line 25, in pylab_setup
globals(),locals(),[backend_name])
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/backend_gtkagg.py",
line 10, in <module>
from matplotlib.backends.backend_gtk import gtk, FigureManagerGTK,
FigureCanvasGTK,\
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/backend_gtk.py",
line 11, in <module>
raise ImportError("Gtk* backend requires pygtk to be installed.")
ImportError: Gtk* backend requires pygtk to be installed.
is any way to help matplotlib to point the where pyGTK is or go around
the problem with another backend?
Thanks,
Nino Hello,
I recently upgraded to Enthought python 2.6 an so I have now matplotlib
0.99.3
My scripts now no longer seem to find the pyGTK since when I run them I
got this message:
Traceback (most recent call last):
File "./sed_plotb_v2.py", line 14, in <module>
from pylab import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/pylab.py",
line 1, in <module>
from matplotlib.pylab import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/pylab.py",
line 247, in <module>
from matplotlib.pyplot import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/pyplot.py",
line 78, in <module>
new_figure_manager, draw_if_interactive, show = pylab_setup()
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/__init__.py",
line 25, in pylab_setup
globals(),locals(),[backend_name])
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/backend_gtkagg.py",
line 10, in <module>
from matplotlib.backends.backend_gtk import gtk, FigureManagerGTK,
FigureCanvasGTK,\
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/backend_gtk.py",
line 11, in <module>
raise ImportError("Gtk* backend requires pygtk to be installed.")
ImportError: Gtk* backend requires pygtk to be installed.
is any way to help matplotlib to point the where pyGTK is or go around
the problem with another backend?
Changing the matplotlibrc to TKAgg works fine though.
Thanks,
Nino
--
Antonino Cucchiara, PhD
Postdoctoral Scholar
Lawrence Berkeley National Lab
UC Berkeley
website: www.astro.psu.edu/~cucchiara/
|
|
From: Antonino C. <acu...@lb...> - 2010-08-09 16:25:59
|
Hello, I am running a MacOS Snow leopard and I recently istalled the python 2.6 via Enthought. I wanted to upgrade the matplotlib 1.0 but when I run the .mpkg the installation don't start because it seems not recognizing the python 2.6 is installed (I do have now 2.6.6). Any suggestions? Thanks, Nino -- Antonino Cucchiara, PhD Postdoctoral Scholar Lawrence Berkeley National Lab UC Berkeley website: www.astro.psu.edu/~cucchiara/ |
|
From: Fernando P. <fpe...@gm...> - 2010-08-09 16:22:52
|
On Mon, Aug 9, 2010 at 8:48 AM, Filipe Fernandes <oc...@gm...> wrote: > > The docstring for sunplots has the "sharex(y) option", but my "ax" are > being created now!? Is that a chicken and egg problem? Or I'm failing to > understand the logic here. Don't worry: when you indicate that you want to share axes (x or y), subplots() tracks that and enables it as it creates the axis objects. Give it a try and see if it works :) Cheers, f |
|
From: Russell O. <ro...@uw...> - 2010-08-09 16:04:54
|
On Aug 9, 2010, at 8:17 AM, Friedrich Romstedt wrote: > 2010/8/7 Russell E. Owen <ro...@uw...>: >> In article <SNT...@ph...>, >> Stephen T. <obs...@ho...> >> wrote: >> >>> Hi, I am having trouble installing matplotlib. I have OS X 10.5 >>> with Python >>> 2.6 >>> downloaded and installed from python.org. >>> (10.5 came with Apple >>> Python 2.5). I've also installed NumPy and SciPy for Python 2.6. >> >> I encourage you to try the matplotlib 1.0.0 binary installer. It was >> built to use the python.org Python (versions are available for Python >> 2.5 and 2.6; the latter did have a known problem with permissions >> on the >> icon files; you can fix that manually or a new installer with that >> problem fixed should be up now or shortly). > > I agree trying that will be an option. > >> Another option is to wade through the build instructions. I've got >> some >> here: >> <http://www.astro.washington.edu/users/rowen/BuildingMatplotlibForMac.html >> > > > Hmm, as I see it this instructions are for building a binary > distribution package of matplotlib, I think this is not what Stephen > wants? The instructions are indeed geared towards building a binary installer, but the final result is a build, plus it is possible to weed out the installer-specific elements. -- Russell |
|
From: Filipe F. <oc...@gm...> - 2010-08-09 15:47:24
|
Hello list, I enjoyed the new feature: fig, axarr = plt.subplots(2, 2) However, I failed to understand how to use the shared axis option with this new feature. The docstring for sunplots has the "sharex(y) option", but my "ax" are being created now!? Is that a chicken and egg problem? Or I'm failing to understand the logic here. Thanks, Filipe. |
|
From: Friedrich R. <fri...@gm...> - 2010-08-09 15:17:45
|
2010/8/7 Russell E. Owen <ro...@uw...>: > In article <SNT...@ph...>, > Stephen T. <obs...@ho...> > wrote: > >> Hi, I am having trouble installing matplotlib. I have OS X 10.5 with Python >> 2.6 >> downloaded and installed from python.org. >> (10.5 came with Apple >> Python 2.5). I've also installed NumPy and SciPy for Python 2.6. > > I encourage you to try the matplotlib 1.0.0 binary installer. It was > built to use the python.org Python (versions are available for Python > 2.5 and 2.6; the latter did have a known problem with permissions on the > icon files; you can fix that manually or a new installer with that > problem fixed should be up now or shortly). I agree trying that will be an option. > Another option is to wade through the build instructions. I've got some > here: > <http://www.astro.washington.edu/users/rowen/BuildingMatplotlibForMac.html> Hmm, as I see it this instructions are for building a binary distribution package of matplotlib, I think this is not what Stephen wants? Dear Stephen, did the mpl-1.0.0 thingy work for you, do you have problems with the icon files, if yes, the instruction inspired by Russell: $ chmod -R a+r [wherever they're living] will fix it I believe. The -R option can be left alone when there is only one level of file hierarchy to fix, but I'm not sure what applies. I really hope we don't have to go through the /opt stuff, because I'm really unsure about how to fix this. Maybe check your $LD_LIBRARY_PATH or similar (I don't recall precisely), if it contains the /opt stuff, we're happy, because it's easy to fix. Say easier. I believe it will be a pain at all anyway. Best would probably be to start with a new, fresh and empty mpl build directory and to go through each step with feedback from the list ... because I don't know precisely what will happen. Friedrich P.S.: I've been busy the past few days, please excuse me. |
|
From: Friedrich R. <fri...@gm...> - 2010-08-09 14:14:16
|
2010/8/9 John Hunter <jd...@gm...>: > On Sun, Aug 8, 2010 at 8:03 PM, Friedrich Romstedt > <fri...@gm...> wrote: >> P.S.: You can also try >> http://matplotlib.sourceforge.net/examples/pylab_examples/alignment_test.html >> , I believe there was some other manual around also covering the >> baseline option, but I cannot find it now. > > The "codex" option on the search page helps with this; you can easily > search for "codex baseline":: > > * the default search page: http://matplotlib.sourceforge.net/search.html > > * what is codex?: > http://matplotlib.sourceforge.net/faq/howto_faq.html#search-examples > > * an example using "codex baseline": > http://matplotlib.sourceforge.net/search.html?q=codex+baseline Thanks, that will be very useful. Actually the page I was looking for was: http://matplotlib.sourceforge.net/examples/pylab_examples/demo_text_rotation_mode.html?highlight=codex%20baseline So far, Friedrich |
|
From: Rob S. <rm...@rm...> - 2010-08-09 07:47:25
|
Eric,
thanks for follow-up! No, I didn't miss it. Saw it Sunday night my time and spent time with my son getting him ready for start of university istead.
Re the setup of Python ... I will do that this week.
Here's the code extract:
#!/usr/bin/env python
# −*− coding: UTF−8 −*−
import matplotlib
matplotlib.use('Agg') # before importing pyplot per docs
import matplotlib.pyplot as plt
import numpy as np
[snipped the import of Python and Django libraries]
###########################################################
def CreateAllWebSite():
# whichever of these is called first is done fine. Second flawed. calling one at at time, each works ok
CreateMemberStatCategoryFigure()
CreateMemberStatFigure()
###############################################
def CreateMemberStatFigure():
"""
This function creates the member statistics bar chart that is published multiple locations.
"""
membertypes=Membertype.objects.filter(active=True).order_by('emailorder').exclude(typecode='EXEC')
mtypes=[]
barchartcolor=[]
mtypecodes=[]
for i in membertypes:
mtypecodes.append(i.typecode)
mtypes.append(i.description)
barchartcolor.append(i.barchartcolor)
memberstatsm=MemberStatistics.monthly_objects.all()
memberstatsp=MemberStatistics.monthlypivotbytype_objects.all()
for i in memberstatsm:
monthend=i['Date']
##### this section in development. a more generic way; but can't get the calls to p=plt to work.
##### proably needs version 1.0 of Matplotlib or something. As it works, optimise and fix later.
# print mtypes,mtypecodes,barchartcolor
# width=24
# month=[]
# for j in memberstatsp:
# month.append(None2Zero(j['month']))
# N=len(month)
# base=np.zeros(N,int) # start off the base with zeros
# for i in membertypes:
# array1=[]
# for j in memberstatsp:
# array1.append(None2Zero(j[i.typecode]))
# array1=np.array(array1)
# p=plt.bar(month,array1,width,bottom=base,linewidth=0)
# base=base+array1
# plt.yticks(np.arange(0,200,20))
# plt.title(ORG_NAME+' Membership by Month')
# plt.ylabel('Count')
# plt.show()
# return
#####
corp1=[]
corp2=[]
corp3=[]
ordm=[]
ordr=[]
ordh=[]
month=[]
for i in memberstatsp:
month.append(None2Zero(i['month']))
corp1.append(None2Zero(i['CORP1']))
corp2.append(None2Zero(i['CORP2']))
corp3.append(None2Zero(i['CORP3']))
ordm.append(None2Zero(i['ORM']))
ordr.append(None2Zero(i['ORMR']))
ordh.append(None2Zero(i['HON']))
N=len(month)
corp1=np.array(corp1)
corp2=np.array(corp2)
corp3=np.array(corp3)
ordm=np.array(ordm)
ordr=np.array(ordr)
ordh=np.array(ordh)
base=np.zeros(N,int)
base1=base+ordh
base2=base1+corp3
base3=base2+corp2
base4=base3+corp1
base5=base4+ordm
width = 24 # the width of the bars: can also be len(x) sequence
p1 = plt.bar(month, ordh, width, color=barchartcolor[0],linewidth=0)
p2 = plt.bar(month, corp3, width, color=barchartcolor[1],bottom=base1,linewidth=0)
p3 = plt.bar(month, corp2, width, color=barchartcolor[2],bottom=base2,linewidth=0)
p4 = plt.bar(month, corp1, width, color=barchartcolor[3],bottom=base3,linewidth=0)
p5 = plt.bar(month, ordm, width, color=barchartcolor[4],bottom=base4,linewidth=0)
p6 = plt.bar(month, ordr, width, color=barchartcolor[5],bottom=base5,linewidth=0)
plt.yticks(np.arange(0,200,20))
plt.title(ORG_NAME+' Membership by Month')
plt.ylabel('Count')
plt.legend( (p1[0], p2[0], p3[0], p4[0], p5[0], p6[0]),mtypes,loc='best')
plt.show()
matplotlib.rcParams['figure.figsize']=(3,2)
fn=TEMP_DIR+SOC_MEMBER_STAT_BARCHART_FIGURE
print " CreateMemberStatFigure(): Saving ",fn,"..."
plt.savefig(fn)
return
###############################################
def CreateMemberStatCategoryFigure():
"""
This function creates the member statistics category bar chart that is published multiple locations.
"""
dt=strftime("%d %B %Y", gmtime())
membercategories=Membercategory.objects.all()
mcats=[]
cnt=[]
for i in membercategories:
mcats.append(i.category)
cnt.append(Member.Active_objects.filter(membercategory__category=i.category).count())
xlocations = np.array(range(len(mcats)))+0.5
print mcats
print cnt
p1 = plt.bar(xlocations,cnt)
plt.figtext(0.15,0.85,dt)
plt.xticks(xlocations+0.4, mcats,rotation=17)
plt.title(ORG_NAME+' Membership by Member Category')
plt.ylabel('Count')
plt.show()
matplotlib.rcParams['figure.figsize']=(3,2)
fn=TEMP_DIR+SOC_MEMBER_STAT_BARCHART_CAT_FIGURE
print " CreateMemberStatCategoryFigure(): Saving ",fn,"..."
plt.savefig(fn)
print " CreateMemberStatCategoryFigure(): ",SOC_MEMBER_STAT_BARCHART_CAT_FIGURE," created ..."
return
################################################
On 9 Aug 2010, at 07:41, Eric Firing wrote:
> Did you miss my reply to the list?
>
> Eric
>
> -------- Original Message --------
> Subject: Re: [Matplotlib-users] Unable to make sequential calls to functions with create matplotlib graphs ... second gets jumbled
> Date: Sun, 08 Aug 2010 08:10:37 -1000
> From: Eric Firing <ef...@ha...>
> Organization: University of Hawaii
> To: mat...@li...
>
> On 08/08/2010 12:53 AM, Rob Schneider wrote:
>> Running 0.98.5.3
>> (would upgrade to 1.0 but having trouble installing it on Mac OS X as it doesn't appear to like the version of Python Apple provides).
>>
>
> Standard procedure on the Mac is to install the python from python.org.
> That way you don't risk fouling up the python that OS X is depending on,
> and at the same time your own code can use the version of python that
> most extension packages are built for.
>
>
>> I have a module where there are two functions which call matplotlib to each create a different graph which both saved to an output PNG file. The import statements:
>>
>> import matplotlib
>> matplotlib.use('Agg')
>> import matplotlib.pyplot as plt
>> import numpy as np
>>
>> are at the top of the module file. Neither function imports anything specifically, relying on the above imports.
>>
>> I call each function sequentially. The result is that the first graph is created correctly. The second graph is flawed, and in fact shows the legend from the first function. When I reverse the function calls, which ever graphing function is called first is ok, but second is flawed. If I call each function on it's own, within the same Python session, the graphs (both) get produced flawlessly.
>>
>> both charts are bar charts; but one does a stacked bar and the other is a simple bar chart.
>>
>> Why would I not be able to call the two functions sequentially? Why does the first call interfere with the second call?
>>
>
> I don't think anyone is going to be able to answer this question until
> you provide a minimal stand-alone code example. Also, the process of
> stripping your code down to the shortest example that displays the
> undesired behavior may show you where the problem lies.
>
> Eric
>
|
|
From: Antonino C. <acu...@lb...> - 2010-08-09 05:30:19
|
Hello,
I recently upgraded to Enthought python 2.6 an so I have now matplotlib
0.99.3
My scripts now no longer seem to find the pyGTK since when I run them I
got this message:
Traceback (most recent call last):
File "./sed_plotb_v2.py", line 14, in <module>
from pylab import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/pylab.py",
line 1, in <module>
from matplotlib.pylab import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/pylab.py",
line 247, in <module>
from matplotlib.pyplot import *
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/pyplot.py",
line 78, in <module>
new_figure_manager, draw_if_interactive, show = pylab_setup()
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/__init__.py",
line 25, in pylab_setup
globals(),locals(),[backend_name])
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/backend_gtkagg.py",
line 10, in <module>
from matplotlib.backends.backend_gtk import gtk, FigureManagerGTK,
FigureCanvasGTK,\
File
"/Library/Frameworks/Python.framework/Versions/6.2/lib/python2.6/site-packages/matplotlib/backends/backend_gtk.py",
line 11, in <module>
raise ImportError("Gtk* backend requires pygtk to be installed.")
ImportError: Gtk* backend requires pygtk to be installed.
is any way to help matplotlib to point the where pyGTK is or go around
the problem with another backend?
Thanks,
Nino
--
Antonino Cucchiara, PhD
Postdoctoral Scholar
Lawrence Berkeley National Lab
UC Berkeley
website: www.astro.psu.edu/~cucchiara/
|
|
From: Antonino C. <acu...@lb...> - 2010-08-09 04:51:33
|
Hello, I am running a MacOS Snow leopard and I recently istalled the python 2.6 via Enthought. I wanted to upgrade the matplotlib 1.0 but when I run the .mpkg the installation don't start because it seems not recognizing the python 2.6 is installed (I do have now 2.6.6). Any suggestions? Thanks, Nino -- Antonino Cucchiara, PhD Postdoctoral Scholar Lawrence Berkeley National Lab UC Berkeley website: www.astro.psu.edu/~cucchiara/ |
|
From: John H. <jd...@gm...> - 2010-08-09 04:37:39
|
On Sun, Aug 8, 2010 at 8:03 PM, Friedrich Romstedt <fri...@gm...> wrote: > Yes, I agree fully, but have been busy the past few days :-) > > Friedrich > > P.S.: You can also try > http://matplotlib.sourceforge.net/examples/pylab_examples/alignment_test.html > , I believe there was some other manual around also covering the > baseline option, but I cannot find it now. > The "codex" option on the search page helps with this; you can easily search for "codex baseline":: * the default search page: http://matplotlib.sourceforge.net/search.html * what is codex?: http://matplotlib.sourceforge.net/faq/howto_faq.html#search-examples * an example using "codex baseline": http://matplotlib.sourceforge.net/search.html?q=codex+baseline Basically, you go to the default mpl homepage or any sub-page, and from there, click the "Search" link, and then enter "codex YOURPHRASE" where codex stands for "code example" and will return all code examples containing your phrase. JDH |
|
From: Markus B. <mar...@gm...> - 2010-08-09 04:19:36
|
Hi, On my Macbook Pro I use Python 2.6 as provided by the Enthought Python Distribution. I ran into some problem with Axes3D so I decided to upgrade to the latest version from source. While trying that I got a similiar error message as discussed in http://www.mail-archive.com/mat...@li.../msg12938.html i.e. error: png.h: No such file or directory In short matplotlib could not find libpng (or png.h from that). I had libpng installed via fink in the usual place /sw/include etc. This seems to be a quite natural choice, so I wondered why matplotlib does not find that out of the box. Following the tips in the above post I looked at basedir in setupext.py For some reason the basedirs for darwin where commented out. Uncommenting the basedirs did the trick for me [1] and matplotlib happily installed with the libpng from fink. Hope this will help other mac users. Thanks for the great work on matplotlib! Cheers, Markus [1] Here the relevant lines for setupext.py 'darwin' : ['/sw/lib/freetype2', '/sw/lib/freetype219', '/usr/ local', '/usr', '/sw'], # it appears builds with darwin are broken because of all the # different flags the deps can be compile with, so I am pushing # people to : # make -f make.osx fetch deps mpl_build mpl_install #'_darwin' : [], |
|
From: Jae-Joon L. <lee...@gm...> - 2010-08-09 03:27:27
|
On Sun, Aug 8, 2010 at 10:38 PM, Simon Friedberger
<sim...@a-...> wrote:
> a) I tried using the twinx() command like in that example but the axes
> seem to be scaled differently i.e. the ticks on the right don't have the
> same spacing as on the left.
>
twinx() creates an axes whose y-axis is independent from the original axes.
> b) Is it necessary to do that with twinx() or is there a way to set the
> labels for both sides independently?
>
Within a same axes, you cannot change the ticklabels of one side
without affecting the other side. This is also true between two axes
with shared axis.
One option would be to sync the limits of two axis manually (or
automatically using event). Another option you may consider is to use
the axes_grid1 toolkit (assuming that you're using mpl v1.0).
from mpl_toolkits.axes_grid1.parasite_axes import SubplotHost
fig = plt.figure()
ax = SubplotHost(fig, 111)
fig.add_subplot(ax)
ax2 = ax.twin() # "twin", not "twinx"
ax2.axis["top"].toggle(ticklabels=False) # make ticklabels at top invisible
ax2.set_yticks([0.,0.5, 1.])
ax2.set_yticklabels(["A", "B", "C"])
-JJ
|
|
From: Wayne W. <sie...@sb...> - 2010-08-09 03:25:22
|
It and scipy work very well. I have 64-bit Win 7, HP Pavilon desktop. A re-examination shows the install files are all exe files, except I think for Python. I'm using 2.5 and need to stay there along with numpy 1.2.0. When you say uninstall, you must mean delete the file under C:\Python. Well, it's really not me that needs the help, it's my partner. He went off to 1.4, and it has caused trouble. Let's not go there. :-) On 8/8/2010 4:33 PM, Stephen George wrote: > On 9/08/2010 9:19 AM, Wayne Watson wrote: > >> See Subject. I use matplotlib, scipy, numpy and possibly one other >> module. If I go to the control panel, I only see numpy listed. Why? I >> use a search and find only numpy and Python itself. How can matplotlib >> and scipy be uninstalled? >> >> > In my Win7 (64bit) I have 32 bit python 2.6 installed. > > matplotlib and numpy show under the add remove program functionality > > "Python 2.6 matplotlib-0.99.3" > "Python 2.6 numpy-1.4.1" > > Along with heaps of other libraries I have installed > > Are you sure matplotlib is installed AND working? > > To remove I can only suggest you install again and then remove > > Steve > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by > > Make an app they can't live without > Enter the BlackBerry Developer Challenge > http://p.sf.net/sfu/RIM-dev2dev > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > -- Wayne Watson (Watson Adventures, Prop., Nevada City, CA) (121.015 Deg. W, 39.262 Deg. N) GMT-8 hr std. time) Obz Site: 39° 15' 7" N, 121° 2' 32" W, 2700 feet "An experiment is a question which science poses to Nature, and a measurement is the recording of Nature’s answer." -- Max Planck Web Page:<www.speckledwithstars.net/> |
|
From: Friedrich R. <fri...@gm...> - 2010-08-09 01:03:39
|
2010/8/8 Simon Friedberger <sim...@a-...>:
> I have found a solution. I'm not sure if it's good or intended but the
> following works:
>
> for label in xax.get_ticklabels():
> label.set_rotation(45)
> label.set_horizontalalignment('left')
This is fully intended. Maybe you can compare with the version
attached, I believe my version should have some minor improvement (the
labels are anchored all with the baseline's leftmost point at the
center of the grid cell). I have not tried your version, though.
You got rid of the +0.4 with your solution I believe?
Also, for the previous pocoo version still online there, I had a
problem with the "superduperverylonglabel". It was shiftet to the
left. What is understandable from the point of view that matplotlib
anchored the labels' center point at x + 0.4.
> Please comment. Apart from that it's here for people who look for a
> solution to the same question.
Yes, I agree fully, but have been busy the past few days :-)
Friedrich
P.S.: You can also try
http://matplotlib.sourceforge.net/examples/pylab_examples/alignment_test.html
, I believe there was some other manual around also covering the
baseline option, but I cannot find it now.
|
|
From: Stephen G. <ste...@op...> - 2010-08-09 00:04:46
|
On 9/08/2010 9:19 AM, Wayne Watson wrote: > See Subject. I use matplotlib, scipy, numpy and possibly one other > module. If I go to the control panel, I only see numpy listed. Why? I > use a search and find only numpy and Python itself. How can matplotlib > and scipy be uninstalled? > In my Win7 (64bit) I have 32 bit python 2.6 installed. matplotlib and numpy show under the add remove program functionality "Python 2.6 matplotlib-0.99.3" "Python 2.6 numpy-1.4.1" Along with heaps of other libraries I have installed Are you sure matplotlib is installed AND working? To remove I can only suggest you install again and then remove Steve |