Re: Log Y-Axis

From: Dave Kennison (kennison@XXXXXX)
Date: Tue Jun 05 2001 - 11:11:57 MDT

  • Next message: Richard Carpenter: "Problems with explicit contour levels"

    Bernard,

    I have been sick and am trying to work from home and I keep getting cut
    off, so it's counter-productive to try to write an example for you, but ...

    To map CONPACK output to a linear/log plot, it should be sufficient to

      1. CALL CPSETI ('SET',0) to tell CONPACK not to do its own SET call.

      2. CALL CPSETR ('XC1',X1) to tell CONPACK what user-system X value is
         associated with a first subscript of 1.

      3. CALL CPSETR ('XCM',XM) to tell CONPACK what user-system X value is
         associated with a first subscript of maximum value.

      4. CALL CPSETR ('YC1',Y1) to tell CONPACK what user-system Y value is
         associated with a second subscript of 1.

      5. CALL CPSETR ('YCN',YN) to tell CONPACK what user-system Y value is
         associated with a second subscript of maximum value.

      6. CALL SET to tell NCAR Graphics how user-system values are to be mapped
         to the plotter frame. Arguments 1-4 tell it what portion of the frame
         to use, arguments 5-8 are X1, XM, Y1, and YN, and argument 9 is a 2.

      7. Do the calls to CPRECT, ARINAM, CPCLAM, etc., that you have now.

      8. Do whatever calls you like to label the axes. I haven't looked at
         your GRIDAL calls in detail, but they seemed all right ...

    I should be back in my office tomorrow and will try to put together an
    example for you then, but the above steps are the key ones, I think.

    Dave Kennison

    > To: ncarg-talk@UCAR.EDU
    > Subject: Log Y-Axis
    >
    > Hi,
    >
    > I am using LLU to do contours. I need to have the Y-Axis on a
    > Logaritmic scale. I tried the following:
    >
    > CALL SETUSV('LS',2)
    >
    > and
    >
    > CALL SET (0.,1.,0.,1.,0.,1.,0.,1.,2)
    >
    >
    > none worked for me.
    >
    > With SETUSV('LS',2) it removes my label on both axis and removes the
    > thick marks on the Y-axis and puts a 10 on top. The data contours are
    > unaffected.
    >
    >
    > To contour I am using:
    >
    > CALL ARINAM (IAMA,800000)
    > CALL CPRECT (ZREG,M,M,K,RWRK,10000,IWRK,12000)
    > CALL CPLBAM (ZREG,RWRK,IWRK,IAMA)
    > CALL CPCLDM (ZREG,RWRK,IWRK,IAMA,CPDRPL)
    > CALL CPLBDR (ZREG,RWRK,IWRK)
    >
    > the axis mapping:
    >
    > CALL CPSETR ('XC1 - X COORDINATE AT I=1',X1)
    > CALL CPSETR ('XCM - X COORDINATE AT I=M',XM)
    > CALL CPSETR ('YC1 - Y COORDINATE AT J=1',Y1)
    > CALL CPSETR ('YCN - Y COORDINATE AT J=N',YN)
    >
    >
    > and for labeling the axis:
    >
    > CALL GASETI('LTY',1)
    > CALL GASETI('WLB',2)
    > CALL LABMOD ('(I4)','(I4)',0,0,10,10,0,0,0)
    > CALL GRIDAL (5,5,4,4,1,1,5,0.,0.)
    >
    >
    > all the contour levels and text labels have been set up prior to these
    > calls. I works fine for linear to linear but the log scaling does not work
    > for me.
    >
    > By scaling the Y axis to log will the data contour follow or it only
    > changes the "look" of the Y-axis?
    >
    >
    > What am I doing wrong?
    >
    >
    > Any help would be appreciated.
    >
    >
    > Thank you
    >
    >
    > Bernard
    >
    > --
    > ----------------------------------------------------------------------
    > Bernard Miville - Meteorologist
    > Canadian Centre for Climate Phone: 1-250-363-3347
    > Modelling and Analysis (CCCMA) Fax: 1-250-363-8247
    > Meteorological Service of Canada E-mail: Bernard.Miville@ec.gc.ca
    > University of Victoria Web: http://www.cccma.bc.ec.gc.ca
    > Post: Courier:
    > P.O. Box 1700 3964 Gordon Head Road, #283
    > Victoria, B.C. V8W 2Y2 Victoria, B.C. V8N 3X3
    > ----------------------------------------------------------------------
    >
    >



    This archive was generated by hypermail 2b29 : Tue Jun 05 2001 - 20:09:17 MDT