PSSCALE(1)

NAME
psscale - Plot gray scale or color scale on maps

SYNOPSIS
psscale -Dxpos/ypos/length/width[h] [ -A[a|l|c] ] [ -B[p|s]parameters ] [ -Ccpt_file ] [ -E[b|f][length] ] [ -I[max_intens|low_i/high_i] ] [ -K ] [ -L[i][gap] ] [ -M ] [ -Ndpi ] [ -O ] [ -P ] [ -Q ] [ -U[just/dx/dy/][c|label] ] [ -V ] [ -X[a|c|r][x-shift[u]] ] [ -Y[a|c|r][y-shift[u]] ] [ -Zzfile ] [ -ccopies ]

DESCRIPTION
psscale plots gray scales or color scales on maps. Both horizontal and vertical scales are supported. For cpt_files with gradational colors (i.e., the lower and upper boundary of an interval have different r/g/b values) psscale will interpolate to give a continuous scale. Variations in intensity due to shading/illumination may be displayed by setting the option -I. Colors may be spaced according to a linear scale, all be equal size, or by providing a file with individual tile widths.

-D  Defines the position of the center/top (for horizontal scale) or center/left (for vertical scale) and the dimensions of the scale. Give a negative length to reverse the scalebar. Append h to get a horizontal scale [Default is vertical].

OPTIONS
No space between the option flag and the associated arguments.

-A  Place annotations and labels above (instead of below) horizontal scalebars and to the left (instead of the right) of vertical scalebars. Append a or l to move only the annotations or the label to the other side. Append c if you want to print a vertical label as a column of characters (does not work with special characters).

-B  Set annotation, tick, and gridline interval for the colorbar. The x-axis label will plot beneath a horizontal bar (or vertically to the right of a vertical bar), except when using -A. As an option, use the y-axis label to plot the data unit to the right of a horizontal bar (and above a vertical bar). If -B is omitted, or no annotation intervals are provided, the default is to annotate every color level based on the numerical entries in the cpt file (which may be overridden by ULB flags in the cpt file). To specify custom text annotations for intervals, you must append ;annotation to each z-slice in the cpt file.

-C  cpt_file is the color palette file to be used. By default all color changes are annotated. To use a subset, add an extra column to the cpt-file with a L, U, or B to annotate Lower, Upper, or Both color segment boundaries (but see -B). If not given, psscale will read stdin. Like grdview, psscale can understand pattern specifications in the cpt file.

-E  Add sidebar triangles for back- and/or foreground colors. Add f or b for only one sidebar triangle [Default gives both]. Optionally, append triangle height [Default is half the barwidth].

-I  Add illumination effects. Optionally, set the range of intensities from - to + max_intens. If not specified, 1 is used. Alternatively, append low/high intensities to specify an asymmetric range [Default is no illumination].

-K  More PostScript code will be appended later [Default terminates the plot system].

-L  Gives equal-sized color rectangles. Default scales rectangles according to the z-range in the cpt-file (Also see -Z). If set, any equal interval annotation set with -B will be ignored. If gap is appended and the cpt table is discrete we will center each annotation on each rectangle, using the lower boundary z-value for the annotation. If i is prepended we annotate the interval range instead. If -I is used then each rectangle will have its constant color modified by the specified intensity.

-M  Force a monochrome graybar using the (television) YIQ transformation.

-N  Effective dots-per-inch for the rectangular image making up the color scale [300].

-O  Selects Overlay plot mode [Default initializes a new plot system].

-P  Selects Portrait plotting mode [Default is Landscape, see gmtdefaults to change this].

-Q  Select logarithmic scale and power of ten annotations. All z-values in the cpt file will be converted to p = log10(z) and only integer p values will be annotated using the 10^p format [Default is linear scale].

-S  Do not separate different colour intervals with black lines.

-U  Draw Unix System time stamp on plot. By adding just/dx/dy/, the user may specify the justification of the stamp and where the stamp should fall on the page relative to lower left corner of the plot. For example, BL/0/0 will align the lower left corner of the time stamp with the lower left corner of the plot. Optionally, append a label, or c (which will plot the command string.). The GMT parameters UNIX_TIME, UNIX_TIME_POS, and UNIX_TIME_FORMAT can affect the appearance; see the gmtdefaults man page for details. The time string will be in the locale set by the environment variable TZ (generally local time).

-V  Selects verbose mode, which will send progress reports to stderr [Default runs "silently"].

-X -Y
    Shift plot origin relative to the current origin by (x-shift,y-shift) and optionally append the length unit (c, i, m, p). You can prepend a to shift the origin back to the original position after plotting, or prepend r [Default] to reset the current origin to the new location. If -O is used then the default (x-shift,y-shift) is (0,0), otherwise it is (r1i, r1i) or (r2.5c, r2.5c). Alternatively, give c to align the center coordinate (x or y) of the plot with the center of the page based on current page size.

-Z  File with colorbar-width per color entry. By default, width of entry is scaled to color range, i.e., z = 0-100 gives twice the width as z = 100-150 (Also see -L).

-c  Specifies the number of plot copies. [Default is 1].

EXAMPLES
To append a vertical color scale (7.5 cm long; 1.25 cm wide) to the right of a plot that is 6 inch wide and 4 inch high, using illumination, and show back- and foreground colors, and annotating every 5 units, use

psscale -D 6.5i/2i/7.5c/1.25c -O -C colors.cpt -I -E -B 5:BATHYMETRY:/:m: >> map.ps

NOTES
When the cpt file is discrete and no illumination is specified, the color bar will be painted using polygons. For all other cases we must paint with an image. Some color printers may give slightly different colors for the two methods given identical RGB values.

SEE ALSO
GMT(1), makecpt(1), grd2cpt(1)