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
(13) |
2
(11) |
3
(2) |
|
4
(4) |
5
(28) |
6
(17) |
7
(28) |
8
(6) |
9
(6) |
10
|
|
11
|
12
(9) |
13
(13) |
14
(21) |
15
(16) |
16
(6) |
17
(3) |
|
18
(3) |
19
(8) |
20
(15) |
21
(33) |
22
(10) |
23
(17) |
24
(2) |
|
25
(5) |
26
(23) |
27
(18) |
28
(6) |
|
|
|
|
From: Matt A. <ma...@ph...> - 2007-02-25 22:43:00
|
The trick is that you want the image coordinates in *screen* coordinates, not printer coordinates. The image coordinates will be screen coordinates if you obtain the imgheight/imgwidth by multipying the figure height/width by 80, not 100. The DPI won't matter if you are manually setting the height/width in the img tag. Alternatively, you could set dpi=80 and skip the imgheight/imgwidth entries altogether (and reformat the vertices correctly for the imagemap input without using the imgheight...). If for some reason you want the displayed image to be larger/smaller than the selected size (here 4inx4in), multiply the matplotlib coordinates by the ratio of the image scaling factor and 80. Ie in your example, multiply the coordinates by 100./80. to obtain the correct coordinates for the image size that you have chosen (here 400pix/400pix instead of the 'natural' size of 320x320 based upon the PNG being a 4"x4" image). Matt Rajarshi Guha-3 wrote: > > Hi, I'm trying to generate a barplot and subsequently dumping it to a > PNG file and making an HTML imagemap out of it. I've pasted my code > below. > > The problem is that the coordinates I need to supply for the imagemap > don't seem to be correct. > > I'm getting the screen coordinates using: > > coords = [] > for rectangle in b: > > vertices = rectangle.get_verts() > > top_left = get_top_left(vertices) > lower_right = get_lower_right(vertices) > > trans = rectangle.get_transform() > top_left = trans.xy_tup(top_left) > lower_right = trans.xy_tup(lower_right) > > coords.append( (top_left, lower_right) ) > > > -- View this message in context: http://www.nabble.com/trying-to-get-screen-coordinates-for-bars-tf3280553.html#a9150522 Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: Fernando P. <fpe...@gm...> - 2007-02-25 22:16:21
|
Hi, On 2/25/07, Jouni K. Sepp=E4nen <jk...@ik...> wrote: > I suppose these things could be addressed quite neatly by IPython. > It could even modify your history similarly to what it currently > does with the %magic commands, so that when you type Feel free to play with implementing this, it's easy to do so on your personal setup, since input prefilter can be trivially added by any user. Once you find a set of tools that you're happy with, just send them my way and we'll include them officially. Here's some links you may find useful: http://ipython.scipy.org/doc/manual/node7.html#SECTION00073000000000000000 http://ipython.scipy.org/doc/manual/node11.html the code for these extensions ships already with ipython, under IPython/Extensions. Look at the one for quantities with units, it's a good starting point for what you want to do. > Perhaps the namespace issue could also be addressed at the IPython > level. The pylab profile could import the various packages, perhaps > with some kind of abbreviated names, and rewrite commands like Ditto. Regards, f |
|
From: <kc1...@ya...> - 2007-02-25 17:42:12
|
After doing some investigation, I discovered that this problem is reproduci= ble using sample programs such as axes_demo.py. Here are the steps I took= :=0A=0Aa) Run axes_demo.py=0Ab) Save the plot as eps file=0Ac) Start Word= =0Ad) Insert the eps file =0Ae) Print=0A=0AI got a 2 page print: 1 for the = plot, and 1 for the error message invalidrestore.=0A=0ACould somebody pleas= e try and see if it fails the same on their system? =0A=0A> -----Original = Message-----=0A> From: mat...@li... =0A> = [mailto:mat...@li...] On =0A> Behalf Of k= c10...@ya...=0A> Sent: Friday, February 23, 2007 4:42 PM= =0A> To: mat...@li...=0A> Subject: Re: [Matplotli= b-users] invalidrestore=0A> =0A> =0A> Thanks for pointing that out, Eric.= =0A> =0A> I try that and it did turn my plot 90 degree. The bad news =0A>= is that GSview imports it upside down and if I want to view =0A> the plot = on the screen, I have to rotate it downside up =0A> first. (Hey, I should= n't complain. At least I can print =0A> without wasting a piece of paper f= or each plot).=0A> =0A> So, looks like it's true that something MPL did to = the eps =0A> file is causing Word to spit out that error page. I wish I = =0A> know what it is.=0A> =0A> The problem of not finding out is that I nee= d to send these =0A> plots to clients. I don't want to require that they h= ave an =0A> .eps viewer in order to see my plots...=0A> =0A> Regards=0A> = =0A> =0A> =0A> > -----Original Message-----=0A> > From: Eric Firing [mailto= :ef...@ha...]=0A> > Sent: Friday, February 23, 2007 3:07 PM=0A> > To= : kc1...@ya...=0A> > Cc: mat...@li...= rge.net=0A> > Subject: Re: [Matplotlib-users] invalidrestore=0A> > =0A> > = =0A> > kc1...@ya... wrote:=0A> > > I installed gsview an= d gscript and tried it. The good =0A> > news is that when I print from in= side gsview, the error page=0A> > is gone. The bad news is that the oriten= tation is wrong. My =0A> > plot is designed for landscape. From word, I s= et the page =0A> > setup to landscape, import the picture, and print. But = with =0A> > gsview, it imports my plot 90 degree wrong. Changing =0A> > o= rientation flips the whole page 90 degree but the plot gets =0A> > rotated = as well and so it still prints wrong.=0A> > > =0A> > > I guess I have no ch= oice but to regress step by step and=0A> > see which MPL=0A> > > feature ag= grevated this condition.=0A> > > =0A> > =0A> > Did you try saving the figur= e using the orientation kwarg? This is=0A> > intended for postscript outpu= t.=0A> > =0A> > e.g.=0A> > =0A> > from pylab import figure, show, close=0A>= > fig =3D figure()=0A> > ax =3D fig.add_subplot(1,1,1)=0A> > ax.plot([0,1]= , [0,1])=0A> > fig.savefig('myplot.ps', orientation=3D'landscape')=0A> > cl= ose(fig)=0A> > =0A> > Eric=0A> > =0A> =0A> --=0A> John Henry=0A> =0A> =0A>= =0A> --------------------------------------------------------------=0A> --= ---------=0A> Take Surveys. Earn Cash. Influence the Future of IT=0A> Join = SourceForge.net's Techsay panel and you'll get the =0A> chance to share you= r opinions on IT & business topics through =0A> brief surveys-and earn cash= =0A> http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge=0A= &CID=3DDEVDEV=0A_______________________________________________=0AMatplotli= b-users mailing list Mat...@li...=0Ahttps://lists= .sourceforge.net/lists/listinfo/matplotlib-users=0A=0A =0A--=0AJohn Henry= =0A=0A |
|
From: <jk...@ik...> - 2007-02-25 16:50:25
|
"Barry Wark" <bar...@gm...> writes:
> Yes, I agree. I wasn't coming at so much from the goal of making Pylab
> a Matlab clone (as you point out, that's silly, and misses much of the
> advantage of Python), but rather from the goal of making interactive
> use as efficient as possible. When I fire up ipython -pylab to do some
> quick exploration, it's nice not to have to type N.blah or pylab.plot
IMHO the greatest strength of Matlab in interactive use is the matrix
input format. For one thing, it is easier to type something like
[0 1 0; 1 0 0; 0 0 1]
than
array([[0,1,0],[1,0,0],[0,0,1]])
Granted, you can often leave out the array() wrapper, but typing all
the commas and brackets and getting the nesting right slows me down
enough that using Python feels like tedious work where Matlab is more
like an Emacs-like extension of the mind. Another neat feature is
auto-flattening: to e.g. add row- and column-wise sums and a grand
total to a matrix M, you can type
[M sum(M,2); sum(M,1) sum(M(:))]
compared to which the r_[] and c_[] syntax feels like an ugly hack.
(Of course, the auto-flattening feature is a disaster for serious
programming (as opposed to quick interactive work), so Matlab has
added cell arrays which don't auto-flatten, leading to no end of
confusion between [] and {} indexing and the need to add {:} in
seemingly random spots in Matlab code.)
I suppose these things could be addressed quite neatly by IPython.
It could even modify your history similarly to what it currently
does with the %magic commands, so that when you type
a = [0 1 0; 1 0 0; 0 0 1]
and then examine your history, you see
a = array([[0,1,0],[1,0,0],[0,0,1]])
which you could copy-paste into the program you are developing.
Perhaps the namespace issue could also be addressed at the IPython
level. The pylab profile could import the various packages, perhaps
with some kind of abbreviated names, and rewrite commands like
a = array(...)
plot(sin(a))
to
a = numpy.array(...)
pylab.plot(numpy.sin(a))
so again you could copy/paste from the history to an editor and get
correctly Pythonic code without any "from ... import *". Probably a
100% solution is quite difficult because of the dynamic features in
Python, but it seems to me that a 80% solution should be feasible.
(Parse the input to an AST using the parser facility in the Python
library, use a tree walker to find all references to functions or
variables, and if they don't exist in locals() or globals() and are
not the target of an assignment anywhere in the AST, replace them by
references to the appropriate package.)
--
Jouni K. Seppänen
http://www.iki.fi/jks
|
|
From: Matthew A. <ma...@ph...> - 2007-02-25 03:14:03
|
Hi all...I am connecting an event handler that collects user input via
raw_input. When using GTKAgg as my backend, this works but requires the
user to first hit 'enter' before the raw_input prompt is displayed--this
extra step of hitting enter is quite cumbersome! When I use the TKAgg
backend, I get this error message:
Exception in Tkinter callback
Traceback (most recent call last):
File "/local/lib/python2.5/lib-tk/Tkinter.py", line 1403, in __call__
return self.func(*args)
File
"/local/lib/python2.5/site-packages/matplotlib/backends/backend_tkagg.py",
line 208, in button_press_event
FigureCanvasBase.button_press_event(self, x, y, num, guiEvent=event)
File "/local/lib/python2.5/site-packages/matplotlib/backend_bases.py",
line 911, in button_press_event
func(mouseevent)
File "tktest.py", line 15, in printpoint
color = str(raw_input("Enter color: "))
RuntimeError: can't re-enter readline
I am using Tcl/Tk 8.4.14, python2.5, and matplotlib0.90. The test code I'm
using follows.
Thanks for any help!
Matt
-----------------
import pylab,scipy
def printpoint(event):
color = str(raw_input("Enter color: "))
text = "%d , %d" % (event.xdata,event.ydata)
pylab.text(event.xdata,event.ydata,text,color=color)
data = scipy.arange(100.)
pylab.plot(data)
pylab.connect('button_press_event',printpoint)
|