How can I produce a plot with both colors and patterns?
Colors and patterns can both be used by using the /LEVELS qualifier to specify different sections of the data to be plotted.
fill/levels=(top
half) data
fill/over/levels=(bottom half)/pal=black/pat=pattern data
The tricky part comes in getting the shade key correct on the right hand side. To get it right it's helpful to use the PPL SHAKEY command and the following symbols defined by plot plus (the graphics package underneath Ferret).
Note: These symbols are only defined after an initial plot is produced.
PPL$XLEN | horizontal axis length in inches |
PPL$YLEN | vertical axis height in inches |
PPL$XORG | horizontal axis origin |
PPL$YORG | vertical axis origin |
The PPL SHAKEY command is described in the shade
key FAQ.
The graphic above was created using the following script:
use coads_climatology
set region/l=1
shade slp
show sym/all
message "Using the
symbols above we create some variables for the ppl shakey command."
let ylo = ($ppl$yorg)
let ymid = ylo + ($ppl$ylen)*3/5 ! 1010 is 3/5 of the way between
980 and 1030
let yhi = ylo + ($ppl$ylen)
let xlo = ($ppl$xorg) + ($ppl$xlen) + .2
let xhi = xlo + .6
fill/set_up/nokey/lev=(1010,1030,2) slp
ppl shakey 1, 1, 0.08, 0, 4, 6, `xlo`, `xhi`, `ymid`, `yhi`
ppl fill
fill/over/set_up/key/lev=(980,1010,5)/pal=black/pat=6patterns
slp
ppl shakey 1, 1, 0.08, 0, 4, 6, `xlo`, `xhi`, `ylo`, `ymid`
ppl fill/over
pattern solid
go fland
Last modified: April 27, 2000