<HTML dir=ltr><HEAD></HEAD>
<BODY text=#000000 bgColor=#ffffff>
<DIV id=idOWAReplyText2161 dir=ltr>
<DIV dir=ltr><FONT face=Arial color=#000000 size=2><FONT face="Times New Roman" size=2>Classification: UNCLASSIFIED</FONT> <BR><FONT face="Times New Roman" size=2>Caveat (s): FOUO</FONT></DIV></DIV>
<DIV id=idSignature96034>
<DIV> </DIV>
<DIV>Ivan,</DIV>
<DIV> </DIV>
<DIV>I have never heard of that one...It sounds like it will be very useful even for other programs.</DIV>
<DIV> </DIV>
<DIV>Thanks.</DIV>
<DIV></FONT><FONT face=Arial color=#000000 size=2> </DIV></FONT>
<DIV><FONT face=Arial color=#000000 size=2>John Ertl</FONT></DIV>
<DIV><FONT face=Arial size=2>Meteorologist</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>FNMOC</FONT></DIV>
<DIV><FONT face=Arial size=2>7 Grace Hopper Ave.</FONT></DIV>
<DIV><FONT face=Arial size=2>Monterey, CA 93943</FONT></DIV>
<DIV><FONT face=Arial size=2>(831) 656-5704</FONT></DIV>
<DIV><FONT face=Arial size=2><A href="mailto:john.ertl@navy.mil" target=_blank>john.ertl@navy.mil</A></FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV>
<DIV><FONT face=Arial color=#000000 size=2><FONT face="Times New Roman" size=2>Classification: UNCLASSIFIED</FONT> <BR><FONT face="Times New Roman" size=2>Caveat (s): FOUO</FONT></DIV></FONT></DIV></DIV>
<DIV dir=ltr><BR>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> Ivan Toman<BR><B>Sent:</B> Thu 8/30/2007 1:05 AM<BR><B>To:</B> GRADSUSR@LIST.CINECA.IT<BR><B>Subject:</B> Re: white space around image<BR></FONT><BR></DIV>
<DIV>Hi! I don't know if it can be done in GrADS directly, but if you print image to file, you can call directly from GrADS script an imagemagick mogrify command that will shave image. For example, after<BR><BR>'printim path/to/the/image/image.png'<BR><BR>call mogrify like this:<BR><BR>'!/usr/bin/mogrify -shave 20x20 path/to/the/image/image.png'<BR><BR>where 20x20 are sizes of shaved space from the image borders.<BR><BR><BR>Ivan<BR><BR><BR>Ertl, John C CIV 63134 wrote:
<BLOCKQUOTE type="cite">
<DIV id=idOWAReplyText61108 dir=ltr>
<DIV dir=ltr><FONT face=Arial color=#000000 size=2><FONT face="Times New Roman" size=2>Classification: UNCLASSIFIED</FONT> <BR><FONT face="Times New Roman" size=2>Caveat (s): FOUO</FONT></FONT></DIV>
<DIV dir=ltr> </DIV>
<DIV dir=ltr><FONT face=Arial color=#000000 size=2><FONT face="Times New Roman">One more problem for today....</FONT></FONT></DIV>
<DIV dir=ltr> </DIV>
<DIV dir=ltr><FONT face=Arial color=#000000 size=2><FONT face="Times New Roman">I have gotten the plots to look great but I have bunch of white space around the plot. Is there a way for GrADS to produce an image that does not have all of the white space around it. I have to make the image about 3in by 3in and the extra white space makes the plot even harder to read. I might be able to do this post process but I would rather get it in GrADS. I was thinking maybe setting the plot size to be the same size as the page size but....any ideas.</FONT></FONT></DIV>
<DIV dir=ltr> </DIV>
<DIV dir=ltr> </DIV>
<DIV dir=ltr><FONT size=2>Thanks again for the great help</FONT></DIV></DIV>
<DIV id=idSignature43714>
<DIV><FONT face=Arial color=#000000 size=2></FONT> </DIV>
<DIV><FONT face=Arial color=#000000 size=2>John Ertl</FONT></DIV>
<DIV><FONT face=Arial size=2>Meteorologist</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>FNMOC</FONT></DIV>
<DIV><FONT face=Arial size=2>7 Grace Hopper Ave.</FONT></DIV>
<DIV><FONT face=Arial size=2>Monterey, CA 93943</FONT></DIV>
<DIV><FONT face=Arial size=2>(831) 656-5704</FONT></DIV>
<DIV><FONT face=Arial size=2><A href="mailto:john.ertl@navy.mil" target=_blank moz-do-not-send="true">john.ertl@navy.mil</A></FONT></DIV>
<DIV> </DIV>
<DIV>
<DIV><FONT face=Arial color=#000000 size=2><FONT face="Times New Roman" size=2>Classification: UNCLASSIFIED</FONT> <BR><FONT face="Times New Roman" size=2>Caveat (s): FOUO</FONT></FONT></DIV></DIV></DIV>
<DIV dir=ltr><BR>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> Mary Jo Nath<BR><B>Sent:</B> Wed 8/29/2007 8:38 AM<BR><B>To:</B> <A class=moz-txt-link-abbreviated href="mailto:GRADSUSR@LIST.CINECA.IT" target=_blank>GRADSUSR@LIST.CINECA.IT</A><BR><B>Subject:</B> Re: adding text to images<BR></FONT><BR></DIV>
<DIV><PRE>John,
I'd use a grads script to return the XY coordinates of the sides of the
plot using "q gxinfo", then use "draw string" to plot labels relative to
the 4 corners. Include something like this to get the X and Y values
of the sides of the plots:
'q gxinfo'
xvalues=sublin(result,3)
yvalues=sublin(result,4)
* xl = plot starts xl inches from left
* xr = plot ends xr inches from left
* yb = plot starts yb inches from bottom
* yt = plot ends yt inches from bottom
xl=subwrd(xvalues,4)
xr=subwrd(xvalues,6)
yb=subwrd(yvalues,4)
yt=subwrd(yvalues,6)
The lower left corner of the plot would be at "xl" "yb". Upper left at
"xl" "yt". Upper right "xr" "yt". Lower right "xr" "yb".
MJ
Ertl, John C CIV 63134 wrote:
> All,
>
> I have a plot that looks great except that when I change the lat/lon
> of the plot area the image resizes and some of the labels that I have
> placed (using draw string) in the corners of the image now no longer
> draw in the correct place (I guess they draw in the same place but the
> image has changed its dimensions. How can I have a label show up in
> the plotted area and stay in the corner even when the plotted area
> changes.
>
> Thanks
>
> John Ertl
</PRE></DIV></BLOCKQUOTE><BR></DIV></BODY></HTML>