|
From: <kc1...@ya...> - 2007-02-21 19:17:29
|
Thanks for the reply, Darren.=0A=0AI didn't post the plot because I don't k= now if the list accept email attachments, and I don't have any space on the= web for file sharing.=0A=0AI'll try to figure out a way to post the plots.= =0A=0ABTW: I called savefig with the filename, and a dpi of 600 and nothing= else. May be that was the problem.=0A=0ARegards,=0A=0A> -----Original Mes= sage-----=0A> From: Darren Dale [mailto:dd...@co...] =0A> Sent: Wednes= day, February 21, 2007 10:54 AM=0A> To: mat...@li....= net=0A> Cc: kc1...@ya...=0A> Subject: Re: [Matplotlib-us= ers] Maximized vs non-maximized output=0A> =0A> =0A> On Wednesday 21 Februa= ry 2007 01:40:59 pm =0A> kc1...@ya... =0A> wrote:=0A> > = Hi list,=0A> >=0A> > I am still fairly new to Matplotlib.=0A> >=0A> > If I = use the default settings, after creating a plot, and save the =0A> > file, = I get a .png file that looks really ugly. However, if I view =0A> > the pl= ot at the screen first (using the show() command), =0A> maximized the =0A> = > plot, and then save the file, I get a very nice looking =0A> .png file. = If =0A> > I am doing lots of plots, obviously I don't want to have to =0A> = sit there =0A> > and view each and every plots, maximize, save, ...=0A> >= =0A> > How can I accomplish this in batch mode?=0A> =0A> We could probably = be of more help if you posted examples of =0A> your "ugly" =0A> and "nice" = pngs. For now I'll take a guess: maybe what you =0A> are seeing is an =0A> = effect of the resolution and figure size? You can pass a dpi =0A> kwarg to = the =0A> savefig command, or you can set it in your rc settings. Also, =0A>= you can set the =0A> figure size by doing "figure(figsize=3D(x,y))", or yo= u can =0A> change the default =0A> figure size in your rc settings. How doe= s your postscript =0A> output look? That =0A> format would not be influence= d by resolution.=0A> =0A> Darren=0A> =0A =0A--=0AJohn Henry=0A=0A |
|
From: <kc1...@ya...> - 2007-02-21 19:38:47
|
Okay, I tried saving using the postscript format, and I end up with the "ug= ly" plot also. In fact, if I maximize the plot and then save as .ps file,= I get ugly plot as well. So, saving it in PS made no difference - that pa= rt is correct but it means I end up with the same font, and dimension as t= he non-maximized version.=0A=0ASomehow, if I maximize the plot using the sh= ow() command, maximize it first, then save it (in png format), I end up wit= h a very nice looking plot. I just wish there is a simple way to accomplis= h that in batch mode.=0A=0ARegards,=0A =0A--=0AJohn Henry=0A=0A----- Origin= al Message ----=0AFrom: "kc1...@ya..." <kc106_2005-matpl= ot...@ya...>=0ATo: mat...@li...=0ASent: Wedne= sday, February 21, 2007 11:17:18 AM=0ASubject: Re: [Matplotlib-users] Maxim= ized vs non-maximized output=0A=0AThanks for the reply, Darren.=0A=0AI didn= 't post the plot because I don't know if the list accept email attachments,= and I don't have any space on the web for file sharing.=0A=0AI'll try to f= igure out a way to post the plots.=0A=0ABTW: I called savefig with the file= name, and a dpi of 600 and nothing else. May be that was the problem.=0A= =0ARegards,=0A=0A> -----Original Message-----=0A> From: Darren Dale [mailto= :dd...@co...] =0A> Sent: Wednesday, February 21, 2007 10:54 AM=0A> To:= mat...@li...=0A> Cc: kc106_2005-matplotlib@yahoo= .com=0A> Subject: Re: [Matplotlib-users] Maximized vs non-maximized output= =0A> =0A> =0A> On Wednesday 21 February 2007 01:40:59 pm =0A> kc106_2005-ma= tpl...@ya... =0A> wrote:=0A> > Hi list,=0A> >=0A> > I am still fairly= new to Matplotlib.=0A> >=0A> > If I use the default settings, after creati= ng a plot, and save the =0A> > file, I get a .png file that looks really ug= ly. However, if I view =0A> > the plot at the screen first (using the show= () command), =0A> maximized the =0A> > plot, and then save the file, I get = a very nice looking =0A> .png file. If =0A> > I am doing lots of plots, ob= viously I don't want to have to =0A> sit there =0A> > and view each and eve= ry plots, maximize, save, ...=0A> >=0A> > How can I accomplish this in batc= h mode?=0A> =0A> We could probably be of more help if you posted examples o= f =0A> your "ugly" =0A> and "nice" pngs. For now I'll take a guess: maybe w= hat you =0A> are seeing is an =0A> effect of the resolution and figure size= ? You can pass a dpi =0A> kwarg to the =0A> savefig command, or you can set= it in your rc settings. Also, =0A> you can set the =0A> figure size by doi= ng "figure(figsize=3D(x,y))", or you can =0A> change the default =0A> figur= e size in your rc settings. How does your postscript =0A> output look? That= =0A> format would not be influenced by resolution.=0A> =0A> Darren=0A> =0A= =0A--=0AJohn Henry=0A=0A=0A=0A=0A |
|
From: <kc1...@ya...> - 2007-02-21 20:45:11
|
Okay, I posted the "ugly" vs "pretty" plots at:=0A=0Ahttp://new.photos.yaho= o.com/kimwaic106/album=0A=0AI stripped out most of the titles and subtitles= but I think you can still see the difference between the two. (Don't worr= y about the middle unintelligble part).=0A=0ARegards,=0A =0A--=0AJohn Henry= =0A=0A----- Original Message ----=0AFrom: "kc1...@ya..."= <kc1...@ya...>=0ATo: mat...@li...= .net=0ASent: Wednesday, February 21, 2007 11:37:54 AM=0ASubject: Re: [Matpl= otlib-users] Maximized vs non-maximized output=0A=0AOkay, I tried saving us= ing the postscript format, and I end up with the "ugly" plot also. In fac= t, if I maximize the plot and then save as .ps file, I get ugly plot as wel= l. So, saving it in PS made no difference - that part is correct but it me= ans I end up with the same font, and dimension as the non-maximized versio= n.=0A=0ASomehow, if I maximize the plot using the show() command, maximize = it first, then save it (in png format), I end up with a very nice looking p= lot. I just wish there is a simple way to accomplish that in batch mode.= =0A=0ARegards,=0A =0A--=0AJohn Henry=0A=0A----- Original Message ----=0AFro= m: "kc1...@ya..." <kc1...@ya...>=0ATo= : mat...@li...=0ASent: Wednesday, February 21, 20= 07 11:17:18 AM=0ASubject: Re: [Matplotlib-users] Maximized vs non-maximized= output=0A=0AThanks for the reply, Darren.=0A=0AI didn't post the plot beca= use I don't know if the list accept email attachments, and I don't have any= space on the web for file sharing.=0A=0AI'll try to figure out a way to po= st the plots.=0A=0ABTW: I called savefig with the filename, and a dpi of 60= 0 and nothing else. May be that was the problem.=0A=0ARegards,=0A=0A> ----= -Original Message-----=0A> From: Darren Dale [mailto:dd...@co...] =0A>= Sent: Wednesday, February 21, 2007 10:54 AM=0A> To: matplotlib-users@lists= .sourceforge.net=0A> Cc: kc1...@ya...=0A> Subject: Re: [= Matplotlib-users] Maximized vs non-maximized output=0A> =0A> =0A> On Wednes= day 21 February 2007 01:40:59 pm =0A> kc1...@ya... =0A> = wrote:=0A> > Hi list,=0A> >=0A> > I am still fairly new to Matplotlib.=0A> = >=0A> > If I use the default settings, after creating a plot, and save the = =0A> > file, I get a .png file that looks really ugly. However, if I view = =0A> > the plot at the screen first (using the show() command), =0A> maximi= zed the =0A> > plot, and then save the file, I get a very nice looking =0A>= .png file. If =0A> > I am doing lots of plots, obviously I don't want to = have to =0A> sit there =0A> > and view each and every plots, maximize, save= , ...=0A> >=0A> > How can I accomplish this in batch mode?=0A> =0A> We coul= d probably be of more help if you posted examples of =0A> your "ugly" =0A> = and "nice" pngs. For now I'll take a guess: maybe what you =0A> are seeing = is an =0A> effect of the resolution and figure size? You can pass a dpi =0A= > kwarg to the =0A> savefig command, or you can set it in your rc settings.= Also, =0A> you can set the =0A> figure size by doing "figure(figsize=3D(x,= y))", or you can =0A> change the default =0A> figure size in your rc settin= gs. How does your postscript =0A> output look? That =0A> format would not b= e influenced by resolution.=0A> =0A> Darren=0A> =0A =0A--=0AJohn Henry=0A= =0A=0A=0A=0A=0A=0A=0A |
|
From: Darren D. <dd...@co...> - 2007-02-21 21:23:19
|
On Wednesday 21 February 2007 03:44:56 pm kc1...@ya... wrote: > Okay, I posted the "ugly" vs "pretty" plots at: > > http://new.photos.yahoo.com/kimwaic106/album > > I stripped out most of the titles and subtitles but I think you can still > see the difference between the two. (Don't worry about the middle > unintelligble part). I dont really see any difference between these two plots, aside from the obvious and expected difference in font size and line width. If you want to pursue this further, please try to be more descriptive than "ugly" and "pretty". Darren |
|
From: Christopher B. <Chr...@no...> - 2007-02-21 21:42:53
|
Darren Dale wrote: > I dont really see any difference between these two plots, aside from the > obvious and expected difference in font size and line width. I suspect that is the OP's issue. Maybe this will help: http://www.scipy.org/Cookbook/Matplotlib/AdjustingImageSize -Chris -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chr...@no... |
|
From: <kc1...@ya...> - 2007-02-21 22:11:08
|
Okay, I uploaded another set of plots. Please take a look at them again. = I hope it's clear this time.=0A=0AI must reiterate that the *only* thing I = did different between the 2 was to do a screen maximize before saving - an= d the fonts, lines, spacing all came out correct. I did not change font or= anything in the code.=0A=0A> -----Original Message-----=0A> From: matplotl= ib-...@li... =0A> [mailto:matplotlib-users-bounce= s...@li...] On =0A> Behalf Of Darren Dale=0A> Sent: Wednesday,= February 21, 2007 1:23 PM=0A> To: mat...@li...= =0A> Subject: Re: [Matplotlib-users] Maximized vs non-maximized output=0A> = =0A> =0A> On Wednesday 21 February 2007 03:44:56 pm =0A> kc106_2005-matplot= li...@ya... =0A> wrote:=0A> > Okay, I posted the "ugly" vs "pretty" plots= at:=0A> >=0A> > http://new.photos.yahoo.com/kimwaic106/album=0A> >=0A> > I= stripped out most of the titles and subtitles but I think you can =0A> > s= till see the difference between the two. (Don't worry about the =0A> > mid= dle unintelligble part).=0A> =0A> I dont really see any difference between = these two plots, =0A> aside from the =0A> obvious and expected difference i= n font size and line width. =0A> If you want to =0A> pursue this further, p= lease try to be more descriptive than "ugly" =0A> and "pretty".=0A> =0A> Da= rren=0A=0A =0A--=0AJohn Henry=0A=0A |
|
From: Darren D. <dd...@co...> - 2007-02-21 22:40:21
|
On Wednesday 21 February 2007 05:10:57 pm kc1...@ya... wrote: > Okay, I uploaded another set of plots. Please take a look at them again. > I hope it's clear this time. It is not. This discussion is semantic; it is not clear what you find ugly about your "ugly" plots. If you don't like the size of your fonts, and the thickness of your lines, you can alter them or change your defaults with rc settings. > I must reiterate that the *only* thing I did different between the 2 was to > do a screen maximize before saving - and the fonts, lines, spacing all > came out correct. I did not change font or anything in the code. Yes, you have made that clear. If you want to know why maximizing the window changes the output, you should read through the link that Chris posted in this thread. > > -----Original Message----- > > From: mat...@li... > > [mailto:mat...@li...] On > > Behalf Of Darren Dale > > Sent: Wednesday, February 21, 2007 1:23 PM > > To: mat...@li... > > Subject: Re: [Matplotlib-users] Maximized vs non-maximized output > > > > > > On Wednesday 21 February 2007 03:44:56 pm > > kc1...@ya... > > > > wrote: > > > Okay, I posted the "ugly" vs "pretty" plots at: > > > > > > http://new.photos.yahoo.com/kimwaic106/album > > > > > > I stripped out most of the titles and subtitles but I think you can > > > still see the difference between the two. (Don't worry about the > > > middle unintelligble part). > > > > I dont really see any difference between these two plots, > > aside from the > > obvious and expected difference in font size and line width. > > If you want to > > pursue this further, please try to be more descriptive than "ugly" > > and "pretty". |
|
From: <kc1...@ya...> - 2007-02-21 23:08:54
|
Thanks for the reply. =0A=0AI saw Chris's note after I posted my last emai= l and yes I think that link is very helpful. I am studying that link and I= think I know what to do now.=0A=0AThanks again (to Chris as well).=0A=0A= =0A> -----Original Message-----=0A> From: Darren Dale [mailto:dd55@cornell.= edu] =0A> Sent: Wednesday, February 21, 2007 2:40 PM=0A> To: matplotlib-use= rs...@li...=0A> Cc: kc1...@ya...=0A> Subjec= t: Re: [Matplotlib-users] Maximized vs non-maximized output=0A> =0A> =0A> O= n Wednesday 21 February 2007 05:10:57 pm =0A> kc106_2005-matplotlib@yahoo.c= om =0A> wrote:=0A> > Okay, I uploaded another set of plots. Please take a = look at them =0A> > again.=0A> > I hope it's clear this time.=0A> =0A> It i= s not. This discussion is semantic; it is not clear what =0A> you find ugly= =0A> about your "ugly" plots. If you don't like the size of your =0A> font= s, and the =0A> thickness of your lines, you can alter them or change your = =0A> defaults with rc =0A> settings.=0A> =0A> > I must reiterate that the *= only* thing I did different =0A> between the 2 =0A> > was to do a screen m= aximize before saving - and the fonts, lines, =0A> > spacing all came out c= orrect. I did not change font or anything in =0A> > the code.=0A> =0A> Yes= , you have made that clear. If you want to know why =0A> maximizing the win= dow =0A> changes the output, you should read through the link that =0A> Chr= is posted in =0A> this thread.=0A> =0A=0A--=0AJohn Henry=0A=0A=0A=0A=0A |