NAME
psxy - Plot lines, polygons, and symbols on maps
SYNOPSIS
psxy files -Jparameters -Rwest/east/south/north[r] [ -A ] [
- Btickinfo ] [ - Ccptfile ] [ -E[x][y][cap][/pen] ] [ -
Fred/green/blue ] [ -Gfill ] [ -H ] [ -K ] [ -L ] [ -N ] [ -
M[flag] ] [ - O ] [ - P ] [ - Ssymbol/size ] [ -
U[/dx/dy/][label] ] [ -V ] [ -Wpen ] [ -Xx-shift ] [ - Yy-
shift ] [ -: ] [ -ccopies ]
DESCRIPTION
psxy reads (x,y) pairs from files [or standard input] and
generates PostScript code that will plot lines, polygons, or
symbols at those locations on a map. If a symbol is
selected and no symbol size given, then psxy will interpret
the third column of the input data as symbol size in inch.
Multiple segment files may be plotted using the -M option.
If no symbols are selected, a line will be drawn. To draw
closed polygons, use -L. Select a shade with -G. If -G is
set, -L will control whether the polygon outline is drawn or
not. If a symbol is selected, -G and -L determines the fill
color and outline/no outline, respectively. The PostScript
code is written to standard output.
files
List one or more file-names. If no files are given,
psxy will read standard input.
-J Selects the map projection. Scale is inch/degree,
1:xxxxx. or width in inch (upper case modifier).
CYLINDRICAL PROJECTIONS:
-Jclon0/lat0/scale (Cassini)
-Jmscale (Mercator - Greenwich and Equator as origin)
-Jmlon0/lat0/scale (Mercator - Give meridian and stan-
dard parallel)
-Joalon0/lat0/azimuth/scale (Oblique Mercator - point
and azimuth)
-Joblon0/lat0/lon1/lat1/scale (Oblique Mercator - two
points)
-Joclon0/lat0/lonp/latp/scale (Oblique Mercator - point
and pole)
- Jqlon0/scale (Equidistant Cylindrical Projection
(Plate Carree))
-Jtlon0/scale (TM - Transverse Mercator)
-Juzone/scale (UTM - Universal Transverse Mercator)
-Jylon0/lats/scale (Basic Cylindrical Projection)
AZIMUTHAL PROJECTIONS:
-Jalon0/lat0/scale (Lambert).
-Jelon0/lat0/scale (Equidistant).
-Jglon0/lat0/scale (Orthographic).
-Jslon0/lat0/scale (General Stereographic)
CONIC PROJECTIONS:
-Jblon0/lat0/lat1/lat2/scale (Albers)
-Jllon0/lat0/lat1/lat2/scale (Lambert)
MISCELLANEOUS PROJECTIONS:
-Jhlon0/scale (Hammer)
-Jilon0/scale (Sinusoidal)
-Jklon0/scale (Eckert VI)
-Jnlon0/scale (Robinson)
-Jrlon0/scale (Winkel Tripel)
-Jwlon0/scale (Mollweide)
NON-GEOGRAPHICAL PROJECTIONS:
-Jpscale (Linear projection for polar (theta,r) coordi-
nates)
-Jxx-scale[l|ppow][/y-scale[l|ppow]] (Linear, log, and
power scaling)
More details can be found in the psbasemap manpages.
-R west, east, south, and north specify the Region of
interest. To specify boundaries in degrees and minutes
[and seconds], use the dd:mm[:ss] format. Append r if
lower left and upper right map coordinates are given
instead of wesn.
OPTIONS
No space between the option flag and the associated argu-
ments.
-A Suppress drawing line segments as great circle Arcs.
[Default draws great circle arcs.]
-B Sets map boundary tickmark intervals. See psbasemap
for details.
-C Give a color palette file and let symbol color be
determined by the z-value in the third column. Must be
used with -S. If used, then additional fields are
shifted over by one column (optional size would be 4th
rather than 3rd field, etc.).
-E Draw error bars. Append x and/or y to indicate which
bars you want to draw. The x and/or y errors must be
stored in the columns after the (x,y) pair [or
(x,y,size) triplet]. The cap parameter indicates the
length of the end-cap on the error bars in inch [0.1].
Pen attributes for error bars may also be set.
[Defaults: width = 1, color = 0/0/0, texture = solid].
-F Sets the color used for Frame and annotation. [Default
is 0/0/0 (black)]
-G Select filling of polygons and symbols. Set the shade
(0 - 255) or color (r/g/b) [Default is no fill]. For
polygons, you may optionally specify -
Gpicon_size/pattern, where pattern gives the number of
the image pattern (1-32) OR the name of a icon-format
file. icon_size sets the unit size in inch. To invert
black and white pixels, use -GP instead of - Gp. See
GMTs Cookbook & Technical Reference Appendix E for
information on individual patterns.
-H Input file(s) has Header record(s). Number of header
records can be changed by editing your .gmtdefaults
file. If used, GMT default is 1 header record.
-K More PostScript code will be appended later [Default
terminates the plot system].
-L If a symbol is selected, -L will draw the symbol out-
line using current pen (see -W). If no symbols are
selected, -L will connect the endpoints of the line-
segment(s) and draw polygons.
-M Multiple segment file. Segments are separated by a
record whose first character is flag. [Default is
'>'].
-N Do NOT skip symbols that fall outside map border
[Default plots points inside border only].
-O Selects Overlay plot mode [Default initializes a new
plot system].
- P Selects Portrait plotting mode [GMT Default is
Landscape, see gmtdefaults to change this].
-S Plot symbols. size is symbol size in inch. Choose
between:
-Sa star. size is radius of circumscribing circle.
-Sb bar extending from base to y. size is bar width. By
default, base = 0. Append /base to change this value.
Append u if size is in x-units [Default is inch].
-Sc circle. size is diameter of circle.
-Sd diamond. size is side of diamond.
-Se ellipse. Direction (in degrees counterclockwise from
horizontal), major_axis (in inch), and minor_axis (in
inch) must be found in columns 3, 4, and 5.
-Sf fault. Give distance gap between ticks and ticklength
in inch. If gap is negative, it is interpreted to mean
number of ticks instead. Append l or r to draw tick on
the left or right side of line [Default is centered].
Upper case L or R draws a triangle instead of line seg-
ment.
-Sh hexagon. Give side in inch.
-Si inverted triangle. Give side in inch.
-Sl letter or text string. Give size in inch, and append
/string after the size. Note that the size is only
approximate; no individual scaling is done for dif-
ferent characters. Remember to escape special charac-
ters like *.
-Sp point. No size needs to be specified (1 pixel is
used).
-Ss square. Give side in inch.
-St triangle. Give side in inch.
-Sv vector. Direction (in degrees counterclockwise from
horizontal) and length (in inch) must be found in
columns 3 and 4. size, if present, will be interpreted
as arrowwidth/headlength/headwidth (in inch) [Default
is 0.03/0.12/0.1 inch]. By default arrow attributes
remains invariant to the length of the arrow. To have
the size of the vector scale down with decreasing size,
append nnorm, where vectors shorter than norm will have
their attributes scaled by length/norm.
-SV Same as -Sv, except azimuth (in degrees east of north)
should be given instead of direction. The azimuth will
be mapped into an angle based on the chosen map projec-
tion (-Sv leaves the directions unchanged.)
-Sx cross. Give length in inch.
-U Draw Unix System time stamp on plot. User may specify
where the lower left corner of the stamp should fall on
the page relative to lower left corner of plot in inch
[Default is (-0.75,-0.75)]. Optionally, append a
label, or c (which will plot the command string.)
-V Selects verbose mode, which will send progress reports
to stderr [Default runs "silently"].
-W Set pen attributes. [Defaults: width = 1, color =
0/0/0, texture = solid].
-X -Y
Shift origin of plot by (x-shift,y-shift) inch
[Default is (1,1) for new plots, (0,0) for overlays].
- : Toggles between (longitude,latitude) and
(latitude,longitude) input/output. [Default is
(longitude,latitude)]
-c Specifies the number of plot copies. [Default is 1]
EXAMPLES
To plot solid red circles (diameter = 0.1 inch) at the posi-
tions listed in the file DSDP.xy on a Mercator map at 2
inch/degree of the area 150E to 154E, 18N to 23N, with tick-
marks every 1 degree and gridlines every 15 minutes, try:
psxy DSDP.xy -R150/154/18/23 -Jm2 -Sc0.1 -G255/0/0 -B1g15m |
lpr
To plot the xyz values in the file quakes.xyzm as circles
with size given by the magnitude in the 4th column and color
based on the depth in the third using the color palette cpt
on a linear map, try
psxy quakes.xyzm -R0/1000/0/1000 -JX6 -Sc - Ccpt - B200 >
map.ps
To plot the file trench.xy on a Mercator map, with white
triangles with sides 0.1 inch on the left side of the line,
spaced every 0.8 inch, use
psxy trench.xy -R150/200/20/50 -Jm0.15 -Sf0.8/0.1L -G255 - L
-B10 | lpr
SEE ALSO
gmt, psbasemap(l), psxyz
REFERENCES
Wessel, P., and W. H. F. Smith, 1995, The Generic Mapping
Tools (GMT) version 3.0 Technical Reference & Cookbook,
SOEST/NOAA.
Wessel, P., and W. H. F. Smith, 1995, New Version of the
Generic Mapping Tools Released, EOS Trans. AGU, 76, p. 329.
Wessel, P., and W. H. F. Smith, 1995, New Version of the
Generic Mapping Tools Released,
http://www.agu.org/eos_elec/95154e.html, Copyright 1995 by
the American Geophysical Union.
Wessel, P., and W. H. F. Smith, 1991, Free Software Helps
Map and Display Data, EOS Trans. AGU, 72, p. 441.