Re: Plot Placement on the Page and the Margins

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Tue, 11 Sep 2007 10:02:28 -0600 (MDT)

Hi John,

By default, NCL wants to draw its graphics to a unit square. This
doesn't bode well when you want to send the output to non-square
output, like an 8.5" x 11" page.

To help get around this, we have created a special resource called
"gsnMaximize" that works with any of the main gsn_xxxx plotting
routines. Set this resource to True:

    res = True
    res_at_gsnMaximize = True
    res@.... ; set other resources as desired
    plot = gsn_xxx_yyyy(...) ; call the plotting routine of choice.

This resource will cause your graphics to be maximized in size of
the output you are using. It will rotate your plot 90 degrees if this
is the best way to maximize the output.

I'm not sure you can completely get rid of margins, however. If your
plot is a perfect square, and you really don't care about any
titles, tickmarks, labelbars, etc, outside of the plot, then you can
maximize its size in the unit square by setting:

    res_at_vpXF = 0.0
    res_at_vpYF = 1.0
    res_at_vpWidthF = 1.0
    res_at_vpHeightF = 1.0

and then don't set gsnMaximize.

Let me know if either of these methods don't work for you.

--Mary

On Mon, 10 Sep 2007, John Overton wrote:

> Hello,
> Hi, I am new to NCL and I'm sure this is a simple question. I am rendering to
> a .pdf file. There is one page per plot(48 plots total). The plots are
> centered on each page. My question is: How do I render the plots so there is
> no margin (top,right,bottom,left)? Is it possible to do this with a pdf
> output? I can successfully remove the title, the labelbar and the legend, so
> that only the plot remains, but the plots are surrounded by white space in
> the pdf pages.
> Also, is there a way to get the size(height, width) the plot will render as?
>
> Thanks,
> John Overton
> _______________________________________________
> ncl-talk mailing list
> ncl-talk_at_ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Sep 11 2007 - 10:02:28 MDT

This archive was generated by hypermail 2.2.0 : Tue Sep 11 2007 - 10:34:39 MDT