[gradsusr] Filling entire plot area issue..

L.B. bcbass2989 at gmail.com
Thu Feb 27 17:07:44 EST 2014


Aha, Thank you Jennifer, that way actually worked!

It's a bit tedious, but I think I can handle that.

Thanks again everyone for your input.

*William (L.B.) LaForce*
Meteorologist
Central Michigan University '13
www.tornadoinsanity.com


On Thu, Feb 27, 2014 at 3:41 PM, Jennifer Adams <jma at cola.iges.org> wrote:

> Here is what I would do:
>
> 1. set parea to the full page: 'set parea 0 11 0 8.5'
>
> 2. Constrain the domain so that the desired area is shown. This can be
> done by limiting the lat/lon dimension environment, by using 'set mpvals',
> or both. GrADS will fill the plot area as best it can while still
> maintaining the proper aspect ratio -- don't worry about whether the plot
> stretches to the very edges of the page, just get the display inside the
> frame to be the way you want it.
>
> 3. call 'q gxinfo' and parse the output to get the size of the frame. E.g.
>
> ga-> q gxinfo
> Last Graphic = Contour
> Page Size = 11 by 8.5
> X Limits = 0.5 to 10.5
> Y Limits = 1.25 to 7.25
> Xaxis = Lon  Yaxis = Lat
> Mproj = 2
>
> Note the The display is 10 inches in X (10.5 minus 0.5) and 6 inches in Y
> (7.25-1.25). This means your plot has an aspect ratio of 1.6667.
>
> 4. Quit grads, then restart with "grads -a 1.6667" instead of using -l or
> -p.
>
> 5. check the 'q gxinfo' output again:
>
> ga-> q gxinfo
> Last Graphic = Contour
> Page Size = 11 by 6.59987
> X Limits = 1.25011 to 9.74989
> Y Limits = 0.75 to 5.84987
> Xaxis = Lon  Yaxis = Lat
> Mproj = 2
>
> 6. Note the different page size. Use these numbers to change your parea
> command:
> 'q gxinfo'
> psz=sublin(result,2)
> xsz=subwrd(psz,4)
> ysz=subwrd(psz,6)
> 'set parea 0 'xsz' 0 'ysz-0.0001
> Rounding issues force me to reduce the y size by a tiny bit in order to
> avoid the message: 'parea values beyond page limits.'
>
> 7. Now redo your display and you'll see that your plot fills the entire
> window. Here is a sample:
>
>
>
> --Jennifer
>
>
>
>
>
> On Feb 27, 2014, at 3:16 PM, L.B. wrote:
>
> I will take a look at the mpvals. I know you can zoom in by reducing the
> lat/lon pairs - guess I should have said I want that full domain plotted :P
>
> *William (L.B.) LaForce*
> Meteorologist
> Central Michigan University '13
> www.tornadoinsanity.com
>
>
> On Thu, Feb 27, 2014 at 3:00 PM, Stephen McMillan <
> smcmillan at planalytics.com> wrote:
>
>> William,
>> You can "zoom in" by reducing the lat and lon ranges before you display
>> the variable.  Also, try using 'set mpvals...' (see
>> http://grads.iges.org/grads/gadoc/gradcomdsetmpvals.html) to specify
>> which areas you wanted included in the plot.
>> Stephen Mc
>>
>>
>> On Thu, Feb 27, 2014 at 2:42 PM, L.B. <bcbass2989 at gmail.com> wrote:
>>
>>> Hello all,
>>>
>>> I have been having an issue of trying to fill the entire plot area.
>>> Usually the extra white space is used for text and such, but in my case I
>>> want to fill the entire plot area (or most of it) and get rid of as much
>>> white space as possible. I have played around with various values for vpage
>>> and parea as well as the image size output (so it is NOT distorted), and it
>>> just seems to re-scale the image, and not let me fill the entire area.
>>> Ideally it would be nice to set your parea>vpage, but that's not possible.
>>> I have posted an example image below. I made the background black to show
>>> you all the excess space. Now obviously the image is not rectangular, and I
>>> have cropped the left and the right side, but how can I get rid of that
>>> excess on the top and bottom without using an external utility to crop it
>>> after the fact?
>>>
>>> Thanks.
>>>
>>> *William (L.B.) LaForce*
>>> Meteorologist
>>> Central Michigan University '13
>>> www.tornadoinsanity.com
>>>
>>> _______________________________________________
>>> gradsusr mailing list
>>> gradsusr at gradsusr.org
>>> http://gradsusr.org/mailman/listinfo/gradsusr
>>>
>>>
>> ***************************************************
>> The information contained in this e-mail message is intended only for the use of the recipient(s) named above and may contain information that is privileged, confidential, and/or proprietary.
>>
>> If you are not the intended recipient, you may not review, copy or distribute this message. If you have received this communication in error, please notify the sender immediately by e-mail, and delete the original message.
>> ***************************************************
>>
>>
>>
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
>>
>>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>
>
> --
> Jennifer M. Adams
> Center for Ocean-Land-Atmosphere Studies (COLA)
> 111 Research Hall, Mail Stop 2B3
> George Mason University
> 4400 University Drive
> Fairfax, VA 22030
>
>
>
>
>
>
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20140227/9fe28bfc/attachment-0001.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Screen Shot 2014-02-27 at 3.39.10 PM.png
Type: image/png
Size: 234052 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20140227/9fe28bfc/attachment-0001.png 


More information about the gradsusr mailing list