Re: map label bar

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Fri Oct 15 2010 - 10:21:54 MDT

Fang,

You are creating a map that is quite a bit thinner (11 degrees lon) than it is wide (about 170 degrees lat). This size of plot is going to cause problems all around, because you barely have room to put a title at the top. You also have subtitles that are going to run into each other. Did you intend to make the plot this thin?

By default, the labelbar tries to be the same width as your plot. You can control this by setting res@pmLabelBarWidthF to something like 0.6. You will also need to increase your font heights manually, because NCL is trying to use font heights based on the size of your plot titles. You can use the lbLabelFontHeightF resource for this.

You could consider using a vertical labelbar:

  res@lbOrientation = "Vertical"

I also set these resources:

     res@gsnMaximize =True
     res@lbOrientation = "vertical"
     res@tiMainFontHeightF = 0.01
     res@gsnStringFontHeightF = 0.007
     res@pmLabelBarWidthF = 0.08
     res@lbLabelFontHeightF = 0.01

This is still not a great plot, but hopefully it helps you get started.

BTW, I forgot to mention earlier that you need to set the gsnPaperXXXX resources when you call gsn_open_wks. Also, you have "gsnPaperOrientation" misspelled.

    wtype = "eps"
    wtype@gsnPaperOrientation = "portrait"
    wtype@gsnPaperWidth = 17
    wtype@gsnPaperHeight = 11
    wtype@gsnPaperMargin = 0.2

    wks = gsn_open_wks(wtype,output)

--Mary

On Oct 14, 2010, at 4:55 PM, Fang, Fan (GSFC-610.2)[ADNET SYSTEMS INC] wrote:

> Using the gsn_csm_contour_map_ce() function, the main plot and the label bar does not seem to scale in the same way. I ran the attached files like
>
> ncl plotmap.ncl 'input="/var/tmp/quikscat_u_v_2009-02-14_00_00:00.nc"' 'output="
> /var/tmp/testmap"'
>
> The label bar at the bottom was bumped off the chart unless I use something like:
>
> res@mpShapeMode = "FreeAspect" ; fixed aspect ratio; skewing map
> res@vpWidthF = 0.8
> res@vpHeightF = 0.6
>
> But a fixed aspect ratio is not really desired.
>
> Since the main plot scaled to fit into the view port, I suspect the label bar is somehow detached from the same scaling. Any easy way to fix this if I need the label bar?
>
> Thanks.
>
> -Fan<plotmap.ncl><quikscat_u_v_2009-02-14_00_00_00.nc>_______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Fri Oct 15 10:22:00 2010

This archive was generated by hypermail 2.1.8 : Tue Oct 19 2010 - 14:38:00 MDT