Index
# Example 7 -- Colour imageplot with superimposed drawings
#
# Contributed 9 Sep 1994 by Jinyu Sheng <sheng@Phys.Ocean.Dal.Ca>.

.cols. = 111
.rows. = 53
.fac. = 0.655
.lx. = 16.0
.ly. = {rpn .lx. .fac. *}
.ybottom1. = 42.57
.ytop1. = 45.93
.xleft1. = 65.47
.xright1. = 58.13

.uscale. = 0.01
.ybottom. = 42.47
.ytop. = 45.93
.xleft. = 65.47
.xright. = 58.13
set arrow size as 20 percent of length
set u scale .uscale.
set v scale .uscale.
.x1. = 1.0
.y1. = 1.
.x2. = 6.0
.y2. = 12.


.xo. = .x1.
.yo. = .y1.
set x margin .xo.
set y margin .yo.
set x size .lx.
set y size .ly.
set line width 0.2
set x grid .xleft. .xright. / .cols.
set x axis .xleft. .xright. -1.
set y grid .ybottom. .ytop. / .rows.
set y axis .ybottom. .ytop. 1.
set x name ""
set y name ""
set font size 0
draw axes frame
open ~/gri/bio_dpth.dat
read grid data .rows. .cols.
close
grid data *= -1

.zmn. = -5
.zmx. = 300
set image range .zmn. .zmx.
set image colorscale hsb  0.666 0.4 1 .zmn. hsb  0.666 1 1 .zmx.
convert grid to image
draw image

set color rgb 0 1 0
set input data window x .xright. .xleft.
set input data window y .ybottom. .ytop.
open ~/gri/coast1.dat
read columns x y
close
set line width 1.5
draw curve filled
open ~/gri/coast2.dat
read columns x y
close
draw curve filled
open ~/gri/coast3.dat
read columns x y
close
draw curve filled

set color rgb 1 1 1
set line width 2.
set input data window x .xright1. .xleft1.
set input data window y .ybottom1. .ytop1.
open ~/gri/velo_setup_t.dat
skip forward 1
read columns x y u v
close
draw arrows
read columns x y u v
59.8 43.0 50 0.0

draw arrows
set font size 12
\label = "50 cm/s"
draw label "\label" centered at 59.55 42.8
set graylevel black
set font size 0
set symbol size 0.05
draw border box .xo.  .yo.  {rpn .xo. .lx. +} {rpn .yo. .ly. +} 0.010  0.075


.cols. = 46
.rows. = 35
.fac. = 1.06
.lx. = 14.0
.ly. = {rpn .lx. .fac. *}

.ybottom. = 43.67
.ytop. = 45.93
.xleft. = 61.67
.xright. = 58.67
set color rgb 1 1 0
draw line from .xright. .ybottom. to .xright. .ytop.
draw line from .xright. .ytop. to .xleft. .ytop.
draw line from .xleft. .ytop. to .xleft. .ybottom.
draw line from .xleft. .ybottom. to .xright. .ybottom.

set color rgb 1 0 0
open /users/po/sheng/input/tide1_pos.dat
read columns x=3 y=2
close
set symbol size 0.4
draw symbol 14

delete grid

.ybottom1. = 43.7
.ytop1. = 45.9
.xleft1. = 61.6
.xright1. = 58.6

.xo. = .x2.
.yo. = .y2.
set x margin .xo.
set y margin .yo.
set x size .lx.
set y size .ly.
set line width 0.2
set x grid .xleft. .xright. / .cols.
set x axis .xleft. .xright. -1.
set y grid .ybottom. .ytop. / .rows.
set y axis .ybottom. .ytop. 1.
set x name ""
set y name ""
set font size 0
draw axes frame
open ~/gri/dbl_dpth.dat
read grid data .rows. .cols.
close
smooth  grid data
grid data *= -1
convert grid to image
draw image


set input data window x .xright. .xleft.
set input data window y .ybottom. .ytop.
set color rgb 0 1 0
open ~/gri/coast1.dat
read columns x y
close
set line width 1.5
draw curve filled
open ~/gri/coast2.dat
read columns x y
close
draw curve filled
open ~/gri/coast3.dat
read columns x y
close
draw curve filled

set color rgb 1 1 1
set input data window x .xright1. .xleft1.
set input data window y .ybottom1. .ytop1.
set line width 2.
open dbl_velo_setup_t.dat
skip forward 1
read columns x y u v
close
draw arrows

set color rgb 1 1 0
set line width 2
draw line from .xright. .ybottom. to .xright. .ytop.
draw line from .xright. .ytop. to .xleft. .ytop.
draw line from .xleft. .ytop. to .xleft. .ybottom.
draw line from .xleft. .ybottom. to .xright. .ybottom.