[Thread Prev][Thread Next][Index]

Re: [ferret_users] Re: How to move plot keys?



Hi Jagadish,
To make dashed lines, you can use the PLOT/DASH qualifier, which allows you to specify dash characteristics, short or long dashes or combinations of short and long.  See PLOT /DASH in the Users Guide.

To get symbols on a line, use  PLOT/SYMBOL/LINE, or PLOT/SYMBOL=nn/LINE, where nn is one of the plot symbols. These are shown in a table linked to the section in the Users Guide under "PLOT/SYMBOL". The symbols are placed at each data location.

To make these special line styles appear in your legend, you will need to make your own version of the legend scripts, and put in these special qualifiers on the PLOT commands in the script so that your legend will match the style of the plot lines.

Ansley

jagadish karmacharya wrote:
Hi all,
 
How can I use different line styles like dashed-dotted, dashed and double-dotted, long dashed etc with plot command without first producing meta file in color image and then converting it to b/w  ?
 
Also, Is it possible to use line with symbols (like those produced with plot/line/sym) in legend using legline script other than specified by number 1-19?
 
Thanks in advance
Jagadish
Billy Kessler <William.S.Kessler@noaa.gov> wrote:
I wrote a set of legend scripts that are more complicated,
but also allow complete flexibility about the legend
(Emily Vanvyve also contributed). The first one is in user
units, the second is no-user units (calls the first after
conver ting to user units):

------------------------- legline.go -------------
\can mode verify
! make a legend line and its label
! arg1=x-value of line starting point (user units)
! arg2=length of line (user units)
! arg3=y-value of line
! arg4=line type (number 1-19)
! arg5=text character height
! arg6=label text
! only gets label position right for positive-up axes

define symbol xend `$1+$2`
define symbol txstart `($xend)+$2/10`
ppl %range ($ppl$ymin1) ($ppl$ymax1) 10 ! get axis range user units
define symbol drop `$5/2` ! half char hgt in inches
define symbol txypos `($3)-(($drop))*((($ppl$range_high))-(($ppl$range_low)))/($ppl$ylen)`
! set pen for a dummy line number (not to interfere)
ppl pen,77,$4
ppl aline 77 $1 $3 ($xend) $3
label ($txstart) ($txypos) -1 0 $5 $6
set mode/last verify
------------------------- legline-nu.go -----------
\can mode verify
! make a legend line and its label (nouser units)
! calls user-unit legline script, but pre-chooses to make nouser units

! arg1=x-value of line starting point (fraction of plot width)
! arg2=length of line (fraction of plot width)
! arg3=y-value of line (fraction of plot height)
! arg4=line type (number 1-19)
! arg5=text character height
! arg6=label text
! only gets label position right for positive-up axes

let xrange `($xaxis_max) - ($xaxis_min)`
let yrange `($yaxis_max) - (($yaxis_min))`
let leg1 `($xaxis_min) + xrange*$1`
let leg2 `xrange*$2`
let leg3 `($yaxis_min) + yrange*$3`

go legline.go `leg1` `leg2` `leg3` $4 $5 "$6"
set mode/last verify
-------------------------

Billy K



Relax. Yahoo! Mail virus scanning helps detect nasty viruses!

[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement