Below is an annotated version of the script graticules_demo.jnl
The /GRATICULE, /HGRATICULE and /VGRATICULE qualifiers forplot commands turn on and control the line type for graticulelines at the tic marks of the axes.
/GRATICULE sets the horizontal and vertical tic marks to bethe same style. The lines may take on the same characteristics as lines that we plot with the Ferret PLOT command: dashed orsolid; colors Black,Red,Green,Blue,LightBlue,Purple, and White (Ferret only)and THICK=1,2, or 3 where 1 is thin and 3 is the thickest.
yes? PLOT/GRAT=dash/i=1:40 sin(i/6)
We can give multiple arguments to the /GRATICULE qualifier within parentheses
yes? USE coads_climatologyyes? SET REGION/X=130E:70W/y=30S:50N/L=1yes? CONTOUR/COLOR=blue/GRAT=(line,COLOR=red) sstyes? GO land thick yes? GO fland
Here is another example of a simple /GRAT qualifier
yes? USE etopo20 yes? SHADE/PAL=dark_land_sea/GRAT=(COLOR=green) rose
Now a time axis.
yes? PLOT/THICK=3/color=blue/GRAT=(COLOR=black,THICK=1) uwnd
If there are large and small tics on the plot, each may havegraticule lines with different characteristics. Recall that time axes and log axes automatically have small tic marks; you can control the tic marks on other axes using the commands listed under "axis, customizing" and "axis, PPLUS commands" in the Ferret Users Guide.
yes? ppl axnmtc,2,2 yes PLOT/THICK/COLOR=blue/GRAT="large=(line),small=(dash,color=lightblue)"/i=1:40 sin(i/6)
Sometimes we might want to make different settings for thehorizontal and vertical graticules; when the two axes representdifferent quantities, such as space and time, or very differentscales. The /HGRATICULE qualifier sets the horizontal graticulesand the /VGRATICULE qualifier sets the vertical graticules.
Here is a plot with a logarithmic axis
yes? DEFINE AXIS/Z/DEPTH dlog=exp(k[k=1:10]) yes? LET fcn = k[gz=dlog] yes? PLOT/VLOG/VLIMITS=1:10000/HGRAT="LARGE(COLOR=red),SMALL(COLOR=lightblue)"/VGRAT fcn
And, a time axis, using only vertical graticulesm, but with small and large tics set differently..
yes? USE monthly_navy_winds yes? PPL AXNMTC 2,2 yes? PLOT/VGRAT="LARGE(line,COLOR=blue),SMALL(dash,COLOR=lightblue)" uwnd[X=180,Y=0,T=1-may-1989:1-may-1992]
yes? PPL AXNMTC 2,1 yes? USE etopo05 yes? SET REGION/X=130E:160E/y=30S:0S yes? SHADE/SET/HGRAT="LARGE=(THICK),SMALL"/VGRAT="LARGE=(THICK),SMALL"\ yes? /PALETTE=topo/LEV=(-9000,-1000,1000)(-1000,-100,100)(-100,0,10) rose yes? PPL XAXIS 130,160,8 yes? PPL YAXIS -30,0,10 yes? PPL SHADE yes? GO fland 5