[Thread Prev][Thread Next][Index]

Re: reverse axis



Hi Muyin,
	You probably noticed an exchange about reversing time axis
in the mail archives quite a while back

http://ferret.wrc.noaa.gov/Ferret/Mail_Archives/fu_99/msg00355.html

I haven't seen anything since then but have discovered a way to
do what you want with one major snag.  You can reverse the data
but the axis values are not the nice months and years one would
like.  However with a little effort one could add movable labels
In my demo below I've taken a case of a multi-year dataset
where the labelling is easier.

Note that the values in the "ppl yaxis" command are the yaxis
limits obtainable using "ppl listsym" and the "ppl taxis"
command uses the "Woods Hole" formatting WYYYYMMDDHHMM for the
start and end dates.

DEMO:

def axis/x=1:10:1 xax ; def axis/t=1-jul-1950:1-jul-2000/npoints=51 tax
def grid/x=xax/t=tax grd
let v=x[g=grd]+l[g=grd]
! first the normal case of time increasing upward
set view left
fill/nokey/title="Normal Timeaxis" v
! then the reversed time axis
set view right
ppl listsym
ppl yaxis,871848,433536
ppl taxis,W195007010000,W200007010000
ppl axset,,,0,0 ; ppl ylab,@sr ! turn off the yaxis labelling
ppl fill,@srReverse Timeaxis
ppl %yaxis,2000.5,1949.5,-5,1


|--****--****-*---*---***--***--|____spillane@pmel.noaa.gov____|
|-*__---*-----*--*-*--*--*-*--*-|_SCIENCE APPLICATIONS SUPPORT_|
|--***--*-----*-*---*-***--***--|____EPIC/Ferret/PlotPlus______|
|-----*-*-----*-*****-*----*----|__Room 2070 Bldg#3 NOAA/PMEL__|
|-****---****-*-*---*-*----*----|____Phone_:_(206)526-6780_____|

On Fri, 1 Jun 2001, Muyin Wang wrote:

> Dear Ferreters:
>  I am trying to do contour plot over time-longitude domain. By default, the
> x-axis is for longitude, and the y axis is for time. However, I'd like to
> reverse the time axis, so the beginning of the time is located at the top of the
> plot instead of at the bottom. Do I have to redefine the time axis to get this
> plot done?
>  Thanks for the help!
> Muyin
>



[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement