[gradsusr] set parea

Simon Krichak shimon at cyclone.tau.ac.il
Tue Aug 23 02:59:00 EDT 2011


Dear Rupak,

Could you kindly post also the defcol1.gs.

Thanks,
Simon Krichak
  ----- Original Message ----- 
  From: Rupak Rajbhandari 
  To: GrADS Users Forum 
  Sent: Tuesday, August 23, 2011 9:40 AM
  Subject: Re: [gradsusr] set parea


  Hi,


  I am pasting a script to print four maps which I tested some time ago.  With some modification, I think you can come up with the one you explained. Except in your case you need three rows and in the bottom row display the map with out displaying anything (set cmax/cmin) and display the cbar. Hope it works.


  Rupak Rajbhandari
  Department of Meteorology
  Trichandra Campus
  Kathmandu


  **********************************************************************************
  *    test vpage
  *
  *    Landscape
  *
  *    Matrix = 2  is 2 x 2
  *    Matrix = 3  is 3 x 3
  *    Matrix = 4  is 4 x 4
  *
  *    for matrix 3 or 4 little modification is needed.
  *
        matrix=2


  'reinit'
  'open  D:\gridded\npl0p10\RF0P10.ctl'
  'set gxout grfill'
  'set mpdset hires'
  'run defcol1.gs'
  *'set vpage off'
  *'set parea off'
  *'set clevs    2   4   6    8   10   15   20   30   40   50  100  500'
  *'set ccols   31  32  33   42   43   51   52   53   62   63   72   73'


  *    margins
  *
       rm=0.75; lm=0.75; tm=0.5; bm=0.5


  *    virtual page limits
  *
       x1=00.0
       x2=11.0
       y1=00.0
       y2=08.5


       nc=matrix
       nr=matrix


  *    spliting factor
  *
       xext=(x2-x1)/nc
       yext=(y2-y1)/nr
       xm=x2-rm/2


  say x1' ' x2' ' y1' ' y2' ' xext' ' yext
  say ' '


       t1=01
       t2=10
       jy=1
       vy1=y1
       vy2=vy1+yext
    while (jy<=nr)
       ix=1
       vx1=x1
       vx2=vx1+xext
       while (ix<=nc)
         'set vpage 'vx1' 'vx2' 'vy1' 'vy2
         'set parea 'x1+lm' 'x2-rm' 'y1+bm' 'y2-tm
  *       'set clevs   .1   2   3    5   10   15   20   30   40   50  100  150'
  *       'set ccols   31  32  33   42   43   51   52   53   62   63   72   73'
         'set font 'ix
         'set string 'ix+2' tc'
         'display sum(rf,t='t1',t='t2')'
         'draw title Rainfall amount for 't1' to 't2' days (mm)'
          if (ix=nc)
             if (jy=nr)
                'cbarn '1' '1' 'xm' 'y1
             else
                'cbarn '1' '1' 'xm' 'y2
             endif
          endif
          t1=t1+10
          t2=t2+10
          vx1=vx2
          vx2=vx2+xext
          ix=ix+1
         'set vpage off'
         'set parea off'
       endwhile
       vy1=vy2
       vy2=vy1+yext
       jy=jy+1
    endwhile




  On Mon, Aug 22, 2011 at 9:59 PM, saeed bayat <saeedbayat7276 at gmail.com> wrote:

    Dear GrADS users,
    I want to plot 4 maps in 1 page. As mentioned in GrADS documentation index, I do that steps but it did not
    give a good result. I want to do like this(below), but it does not work!

    Please give me an Idea

    Best Regards

    Saeed Bayat
    M.A Student of Climatology
    Department of Geography
    Ferdowsi University of Mashhad(Iran)

    _______________________________________________
    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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20110823/84fcdca4/attachment-0003.html 


More information about the gradsusr mailing list