PSXY
Section: Misc. Reference Manual Pages (l)
Updated: DATE
Index
Return to Main Contents
#ifdef SI
#define UNIT cm
#define PARAMS 0.075/0.3/0.25
#define CAP 0.25
#define LEN_1 0.25
#define LEN_2 5
#define OPT_1 -Jm5 -Sc0.25
#define OPT_2 -JX15
#define LEN_3 2
#define OPT_3 -Jm0.4 -Sf2/0.25L
#else
#define UNIT inch
#define PARAMS 0.03/0.12/0.1
#define CAP 0.1
#define LEN_1 0.1
#define LEN_2 2
#define OPT_1 -Jm2 -Sc0.1
#define OPT_2 -JX6
#define LEN_3 0.8
#define OPT_3 -Jm0.15 -Sf0.8/0.1L
#endif
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 UNIT. 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.
#include "explain_-j.txt"
#include "explain_-R.txt"
OPTIONS
No space between the option flag and the associated arguments.
- -A
-
Suppress drawing line segments as great circle Arcs. [Default draws great circle arcs.]
#include "explain_-b.txt"
- -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 UNIT [CAP]. 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 UNIT.
To invert black and white pixels, use -GP instead of -Gp. See GMTs Cookbook & Technical Reference
APpendix E for
information on individual patterns.
#include "explain_-H.txt"
#include "explain_-K.txt"
- -L
-
If a symbol is selected, -L will draw the symbol outline 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].
#include "explain_-O.txt"
#include "explain_-P.txt"
- -S
-
Plot symbols. size is symbol size in UNIT. 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 UNIT].
- -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 UNIT), and minor_axis (in UNIT) must be found in columns 3, 4, and 5.
- -Sf
-
fault. Give distance gap between ticks and ticklength in UNIT. 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 segment.
- -Sh
-
hexagon. Give side in UNIT.
- -Si
-
inverted triangle. Give side in UNIT.
- -Sl
-
letter or text string. Give size in UNIT, and append /string after the size. Note that the size is only approximate; no individual scaling
is done for different characters. Remember to escape special characters like *.
- -Sp
-
point. No size needs to be specified (1 pixel is used).
- -Ss
-
square. Give side in UNIT.
- -St
-
triangle. Give side in UNIT.
- -Sv
-
vector. Direction (in degrees counterclockwise from horizontal) and length (in UNIT) must be found in columns 3 and 4. size,
if present, will be interpreted as arrowwidth/headlength/headwidth (in UNIT) [Default is PARAMS UNIT].
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 projection (-Sv leaves the directions
unchanged.)
- -Sx
-
cross. Give length in UNIT.
#include "explain_-U.txt"
#include "explain_-V.txt"
- -W
-
Set pen attributes. [Defaults: width = 1, color = 0/0/0, texture = solid].
#include "explain_-XY.txt"
#include "explain_-t.txt"
#include "explain_-c.txt"
EXAMPLES
To plot solid red circles (diameter = LEN_1 UNIT) at the positions listed in the file DSDP.xy on a
Mercator map at LEN_2 UNIT/degree of the area 150E to 154E, 18N to 23N, with tickmarks every 1 degree
and gridlines every 15 minutes, try:
psxy DSDP.xy -R150/154/18/23 OPT_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 OPT_2 -Sc -Ccpt -B200 > map.ps
To plot the file trench.xy on a Mercator map, with white triangles with sides LEN_1 UNIT on the left side of the line, spaced every LEN_3 UNIT, use
psxy trench.xy -R150/200/20/50 OPT_3 -G255 -L -B10 | lpr
SEE ALSO
gmt, psbasemap, psxyz
#include "refs.i"
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- OPTIONS
-
- EXAMPLES
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 07:11:06 GMT, January 07, 2025