There are 18 GMT programs that directly create (or add overlays to) plots (Table 2.1); the remaining 45 are mostly concerned with data processing. This session will focus on the task of plotting lines, symbols, and text on maps. We will build on the skills we acquired while familiarizing ourselves with the various GMT map projections as well as how to select a data domain and boundary annotations.
|
Plotting lines and symbols, psxy is one of the most frequently used programs in GMT. In addition to the common command line switches it has numerous specific options, and expects different file formats depending on what action has been selected. These circumstances make psxy harder to master than most GMT tools. Table 2.2 shows a complete list of the options.
|
The symbols can either be transparent (using -W only, not -G) or solid (-G, with optional outline using -W). The -S option takes the code for the desired symbol and optional size information. If no symbol is given it is expected to be given in the last column of each record in the input file. The size is optional since individual sizes for symbols may also be provided by the input data. The main symbols available to us are shown in Table 2.3.
|
Because some symbols require more input data than others, and because the
size of symbols as well as their color can be determined from the input data,
the format of data can be confusing. The general format for the input data
is (optional items are in brackets []):
[ ] [ ] [ ] [ ] [ ]
Thus, the only required input columns are the first two which must contain the longitude and latitude (or x and y). The remaining items apply when one (or more) of the following conditions are met:
Before we try some examples we need to review two key switches; they specify pen attributes and symbol or polygon fill. Please consult Chapter 4 in the GMT Technical Reference and Cookbook before experimenting with the examples below.