! bn_multi_decade.jnl
! New default no-small tics for multi-decade plots
! See bug 670

def axis/t="01-JAN-1860":"30-DEC-2300":1/edges/units="years"/cal="360d" simutaxis1
let tvar = t[gt=simutaxis1]*-1E+34

define view/x=0:1/y=0.000:0.125 v1
define view/x=0:1/y=0.125:0.250 v2
define view/x=0:1/y=0.250:0.375 v3
define view/x=0:1/y=0.375:0.500 v4
define view/x=0:1/y=0.500:0.625 v5
define view/x=0:1/y=0.625:0.750 v6
define view/x=0:1/y=0.750:0.875 v7
define view/x=0:1/y=0.875:1.000 v8

! Plot a variety of time axis lengths.
set view v1; plot/nolab/ax=0,1,0,0/vlim=0:1 tvar[t=1-jan-1860:1-jan-1870]
set view v2; plot/nolab/ax=0,1,0,0/vlim=0:1 tvar[t=1-jan-1860:1-jan-1880]

! New default: no small tics for multi-decade plots
set view v3; plot/nolab/ax=0,1,0,0/vlim=0:1 tvar[t=1-jan-1860:1-jan-1890]
set view v4; plot/nolab/ax=0,1,0,0/vlim=0:1 tvar[t=1-jan-1860:1-jan-2000]
set view v5; plot/nolab/ax=0,1,0,0/vlim=0:1 tvar[t=1-jan-1860:1-jan-2060]
set view v6; plot/nolab/ax=0,1,0,0/vlim=0:1 tvar[t=1-jan-1860:1-jan-2160]
set view v7; plot/nolab/ax=0,1,0,0/vlim=0:1 tvar

! can plot the tics even on a multi-decade axis by specifying PPL TICS.
set view v8; plot/nolab/ax=0,1,0,0/vlim=0:1/set tvar
  ppl tics,0.1,0.25
  ppl plot 

cancel view

! Test vertical time axes.

define view/x=0.000:0.125/y=0:1 v1
define view/x=0.125:0.250/y=0:1 v2
define view/x=0.250:0.375/y=0:1 v3
define view/x=0.375:0.500/y=0:1 v4
define view/x=0.500:0.625/y=0:1 v5
define view/x=0.625:0.750/y=0:1 v6
define view/x=0.750:0.875/y=0:1 v7
define view/x=0.875:1.000/y=0:1 v8

! Plot a variety of time axis lengths.
set view v1; plot/trans/nolab/ax=0,0,1,0/hlim=0:1 tvar[t=1-jan-1860:1-jan-1870]
set view v2; plot/trans/nolab/ax=0,0,1,0/hlim=0:1 tvar[t=1-jan-1860:1-jan-1880]

! New default: no small tics for multi-decade plots
set view v3; plot/trans/nolab/ax=0,0,1,0/hlim=0:1 tvar[t=1-jan-1860:1-jan-1890]
set view v4; plot/trans/nolab/ax=0,0,1,0/hlim=0:1 tvar[t=1-jan-1860:1-jan-2000]
set view v5; plot/trans/nolab/ax=0,0,1,0/hlim=0:1 tvar[t=1-jan-1860:1-jan-2060]
set view v6; plot/trans/nolab/ax=0,0,1,0/hlim=0:1 tvar[t=1-jan-1860:1-jan-2160]
set view v7; plot/trans/nolab/ax=0,0,1,0/hlim=0:1 tvar

! can plot the tics even on a multi-decade axis by specifying PPL TICS.
set view v8; plot/trans/nolab/ax=0,0,1,0/hlim=0:1/set tvar
  ppl tics,0.1,0.25
  ppl plot 
