Re: panel plot size

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Wed, 30 May 2007 14:37:35 -0600

[1] You have 60x70 degrees [pretty square :-)]
        res_at_mpMinLonF = 150
        res_at_mpMaxLonF = 220
        res_at_mpMinLatF = 0
        res_at_mpMaxLatF = 60

[2] You are using a cylindrical equidistant projection
        gsn_csm_contour_map_ce
    which will use the ratio [lat]/[lon]

[3] Maybe what you want is

 
      res_at_mpShapeMode = "FreeAspect"
      res_at_vpWidthF = 0.9
      res_at_vpHeightF = 0.3

      see: http://www.ncl.ucar.edu/Applications/tropical.shtml
           Example 4

      Also, see use of vpXf
           res_at_vpXF = 0.1 ; start plot at x ndc coord
      http://www.ncl.ucar.edu/Applications/Scripts/xy_5.ncl

> Hi All,
>
> I am trying to make three plots in one page and want to the ratio of width
> to height is ~3, (plot's width is around of 95% of page width). I tried
> changing portrait to landscape and
> resP_at_gsnMaximize = True
> resP_at_gsnPaperWidth = 11
> resP_at_gsnPaperHeight = 8
> It doesn't work. The plots are still square.
> Following is the script i used. Appreciate for any helps!
>
> Chao
>
>
> ------------------
> ; $Id$
>
> ; Purpose: Read and plot SeaWiFs CHL data
>
>
> begin
>
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/shea_util.ncl"
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"
>
> ; Initialize some fields
> diri = "./" ; input dir
> fili_1 = "corre_chl_dep.nc" ; input file name
> fl_in_1 = addfile(diri+fili_1,"r")
> ; print(fl_in)
> data_1 = fl_in_1->prep_dep_corre
> data_2 = fl_in_1->chl_prep_corre
> data_3 = fl_in_1->chl_dep_corre
> data_1@_FillValue =-9999
> data_2@_FillValue =-9999
> data_3@_FillValue =-9999
> printMinMax(data_1, True)
> printMinMax(data_2, True)
> printMinMax(data_3, True)
>
> gsn_define_colormap(wks_id,"BlAqGrYeOrRe") ; choose colormap
> plot = new(3,graphic)
>
> res = True
> ;res_at_gsnLeftString = "correlation coefficient"
> res_at_tiMainString = "Correlation coeffficients between Prep. and dst dep."
> res_at_mpPerimOn = True
> res_at_mpFillOn = True ;if True, then use below
> res_at_cnFillOn = True
> res_at_cnLineLabelsOn = False
> res_at_txFontHeightF = 0.015
> res_at_cnLinesOn = False
>
> res_at_gsnDraw = False
> res_at_gsnFrame = False
> res_at_cnInfoLabelOn = False
> ;res_at_gsnSpreadColorStart = 2
> ;res_at_gsnSpreadColorEnd = 21
> res_at_lbLabelBarOn = True
> res_at_cnFillOn = True
>
> ;;;; set boundary for subregion plot
> res_at_mpLimitMode = "LatLon"
> res_at_mpMinLonF = 150
> res_at_mpMaxLonF = 220
> res_at_mpMinLatF = 0
> res_at_mpMaxLatF = 60
> res_at_mpPerimOn = True
> res_at_mpCenterLonF =185
> res_at_mpCenterLatF = 30
> res_at_gsnSpreadColors = True
> res_at_lbLabelFontHeightF = 0.015
> res_at_tiMainFontHeightF = .018
> res_at_cnFillColors = (/ 5,20,35,50,0,0,65,75,85,96/)
> res_at_cnLevelSelectionMode = "ExplicitLevels" ; set explicit contour levels
> res_at_cnLevels = (/ -0.8,-0.6,-0.4,-0.2,0,0.2,0.4,0.6,0.80/)
> if (isatt(res,"gsnSpreadColors")) then
> delete(res_at_gsnSpreadColors) ; can not have when cnFillColos is set
> end if
> plot(0) = gsn_csm_contour_map_ce(wks_id,data_1,res)
> res_at_gsnStringFont = "simplex_roman"
> res_at_tiMainString = "Correlation coeffficients between Prep. and CHL"
> plot(1) = gsn_csm_contour_map_ce(wks_id,data_2,res)
> res_at_tiMainString = "Correlation coeffficients between CHL and dust dep"
> plot(2) = gsn_csm_contour_map_ce(wks_id,data_3,res)
>
>
> resP = True
> resP_at_cnFillColors = (/ 5,20,35,50,0,0,65,75,85,96/)
> resP_at_gsnMaximize = True
> resP_at_lbLabelBarOn = True
> resP_at_gsnPaperOrientation = "portrait"
> resP_at_lbOrientation = "horizontal"
> resP_at_lbLabelAutoStride = True ; nice label bar labels
> resP_at_lbTitleOn = True
> resP_at_lbLabelFont = "helvetica"
> resP_at_lbTitlePosition = "Bottom"
> resP_at_lbTitleFontHeightF = .012
> resP_at_lbTitleDirection = "Across"
> gsn_panel(wks_id,plot,(/3,1/),resP)
>
> frame(wks_id)
> end ; end amsre()
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk_at_ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>

-- 
======================================================
Dennis J. Shea                  tel: 303-497-1361    |
P.O. Box 3000                   fax: 303-497-1333    |
Climate Analysis Section                             |
Climate & Global Dynamics Div.                       |
National Center for Atmospheric Research             |
Boulder, CO  80307                                   |
USA                        email: shea 'at' ucar.edu |
======================================================
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Wed May 30 2007 - 14:37:35 MDT

This archive was generated by hypermail 2.2.0 : Wed May 30 2007 - 16:42:09 MDT