Modules (Classic Mode)

Note

Looking for the modern mode modules like begin and figure? See the equivalent page for modern mode.

This is a list of all GMT “classic mode” core and supplemental modules and their uses, as well as some utility scripts. These modules are fully compatible with GMT 4 and 5. All modules are requested via a call to the gmt program.

Program

Core Modules

Supplemental Modules

Utility Scripts

Plotting

gmtlogo

Plot the GMT logo

grdcontour

Make contour map using a grid

grdimage

Project and plot grids or images

grdvector

Plot vector field from two component grids

grdview

Create 3-D perspective image or surface mesh from a grid

psbasemap

Plot base maps and frames

psclip

Initialize or terminate polygonal clip paths

pscoast

Plot continents, countries, shorelines, rivers, and borders

pscontour

Contour table data by direct triangulation

psevents

Plot event symbols, lines, polygons and labels for one moment in time

pshistogram

Calculate and plot histograms

psimage

Plot raster or EPS images

pslegend

Plot a legend

psmask

Clip or mask map areas with no data table coverage

psrose

Plot a polar histogram (rose, sector, windrose diagrams)

psscale

Plot gray scale or color scale bar

pssolar

Plot day-light terminators and other sunlight parameters

psternary

Plot data on ternary diagrams

pstext

Plot or typeset text

pswiggle

Plot z = f(x,y) anomalies along tracks

psxy

Plot lines, polygons, and symbols in 2-D

psxyz

Plot lines, polygons, and symbols in 3-D

Filtering

blockmean

Block average (x,y,z) data tables by mean estimation

blockmedian

Block average (x,y,z) data tables by median estimation

blockmode

Block average (x,y,z) data tables by mode estimation

dimfilter

Directional filtering of grids in the space domain

filter1d

Time domain filtering of 1-D data tables

grdfilter

Filter a grid in the space (or time) domain

Gridding

greenspline

Interpolate using Green’s functions for splines in 1-3 dimensions

nearneighbor

Grid table data using a "Nearest neighbor" algorithm

sphinterpolate

Spherical gridding in tension of data on a sphere

surface

Grid table data using adjustable tension continuous curvature splines

triangulate

Delaunay triangulation or Voronoi partitioning and gridding of Cartesian data

grdinterpolate

Interpolate a 3-D cube, 2-D grids or 1-D series from a 3-D data cube or stack of 2-D grids

Sampling of 1-D and 2-D data

gmtsimplify

Line reduction using the Douglas-Peucker algorithm

grdsample

Resample a grid onto a new lattice

grdtrack

Sample one or more grids at specified locations

sample1d

Resample 1-D table data using splines

Projection and map-transformation

grdproject

Forward and inverse map transformation of grids

mapproject

Forward and inverse map transformations, datum conversions and geodesy

project

Project data onto lines or great circles, or generate tracks

Information retrieval

gmtdefaults

List current GMT default settings

gmtget

Get individual GMT default settings or download data sets

gmtinfo

Get information about data tables

gmtset

Change individual GMT default settings

grdinfo

Extract information from 2-D grids or 3-D cubes

grdselect

Make selections or determine common regions from 2-D grids, images or 3-D cubes

Mathematical operations on tables or grids

gmtmath

Reverse Polish Notation (RPN) calculator for data tables

makecpt

Make GMT color palette tables

spectrum1d

Compute auto- [and cross-] spectra from one [or two] time series

sph2grd

Compute grid from spherical harmonic coefficients

sphdistance

Create Voronoi distance, node, or natural nearest-neighbor grid on a sphere

sphtriangulate

Delaunay or Voronoi construction of spherical data

Convert or extract subsets of data

gmtbinstats

Bin spatial data and determine statistics per bin

gmtconnect

Connect individual lines whose end points match within tolerance

gmtconvert

Convert, paste, or extract columns from data tables

gmtselect

Select data table subsets based on multiple spatial criteria

gmtspatial

Geospatial operations on points, lines and polygons

gmtsplit

Split xyz[dh] data tables into individual segments

gmtvector

Operations on Cartesian vectors in 2-D and 3-D

grd2kml

Create KML image quadtree from single grid

grd2xyz

Convert grid to data table

grdblend

Blend several partially overlapping grids into one larger grid

grdconvert

Convert between different grid formats

grdcut

Extract subregion from a grid or image or a slice from a cube

grdpaste

Join two grids along their common edge

xyz2grd

Convert data table to a grid

Grid operations

grd2cpt

Make linear or histogram-equalized color palette table from grid

grdclip

Clip the range of grid values

grdedit

Modify header or content of a grid

grdfft

Mathematical operations on grids in the spectral domain

grdfill

Interpolate across holes in a grid

grdgradient

Compute directional gradients from a grid

grdhisteq

Perform histogram equalization for a grid

grdlandmask

Create a "wet-dry" mask grid from shoreline data base

grdmask

Create mask grid from polygons or point coverage

grdmath

Reverse Polish Notation (RPN) calculator for grids (element by element)

grdmix

Blending and transforming grids and images

grdvolume

Calculate grid volume and area constrained by a contour

Miscellaneous

batch

Automate batch job processing

docs

Show HTML documentation of specified module

gmt2kml

Convert GMT data table to Google Earth KML file

grdgdal

Execute GDAL raster programs from GMT

gmtwhich

Find full path to specified files

kml2gmt

Extract GMT table data from Google Earth KML files

psconvert

Convert [E]PS file(s) to other formats using Ghostscript

geodesy

earthtide

Compute grids or time-series of solid Earth tides

gpsgridder

Interpolate GPS velocities using Green’s functions for elastic deformation

psvelo

Plot velocity vectors, crosses, anisotropy bars and wedges

GSFML

fzanalyzer

Analysis of fracture zones using crossing profiles

fzblender

Produce a smooth blended FZ trace

fzinformer

Bash script to plot statistical information related to fracture zones

fzmapper

Bash script to plot fracture zone cross-profiles on a Mercator map

fzmodeler

Bash script to build fracture zone cross-profile model

fzprofiler

Bash script to plot fracture zone cross-profiles

mlconverter

Convert chrons to ages using selected magnetic timescale

GSHHG

gshhg

Extract data tables from binary GSHHG or WDBII data files

IMG

img2grd

Extract a subset from an img file in Mercator or Geographic format

MGD77

mgd77convert

Convert MGD77 data to other formats

mgd77header

Create MGD77 headers from A77 files

mgd77info

Extract information about MGD77 files

mgd77list

Extract data from MGD77 files

mgd77magref

Evaluate the IGRF or CM4 magnetic field models

mgd77manage

Manage the content of MGD77+ files

mgd77path

Return paths to MGD77 cruises and directories

mgd77sniffer

Along-track quality control of MGD77 cruises

mgd77track

Plot track-lines of MGD77 cruises

potential

gmtflexure

Compute flexural deformation of 2-D loads, forces, and bending moments

gmtgravmag3d

Compute the gravity/magnetic anomaly of a 3-D body by the method of Okabe

gravfft

Spectral calculations of gravity, isostasy, admittance, and coherence for grids

gravprisms

Compute geopotential anomalies over 3-D vertical prisms

grdflexure

Compute flexural deformation of 3-D surfaces for various rheologies

grdgravmag3d

Computes the gravity effect of one (or two) grids by the method of Okabe

grdredpol

Compute the Continuous Reduction To the Pole, AKA differential RTP

grdseamount

Create synthetic seamounts (Gaussian, parabolic, polynomial, cone or disc; circular or elliptical)

talwani2d

Compute geopotential anomalies over 2-D bodies by the method of Talwani

talwani3d

Compute geopotential anomalies over 3-D bodies by the method of Talwani

SEGY

pssegyz

Plot a SEGY file in 3-D

pssegy

Plot a SEGY file in 2-D

segy2grd

Converting SEGY data to a grid

seis

pscoupe

Plot cross-sections of focal mechanisms

psmeca

Plot focal mechanisms

pspolar

Plot polarities on the lower hemisphere of the focal sphere

pssac

Plot seismograms in SAC format

grdshake

Compute Peak Ground Acceleration/Velocity and Intensity

grdvs30

Convert topographic slope to Vs30 velocities

spotter

backtracker

Generate forward and backward flowlines and hotspot tracks

gmtpmodeler

Evaluate a plate motion model at given locations

grdpmodeler

Evaluate a plate motion model on a geographic grid

grdrotater

Finite rotation reconstruction of geographic grid

grdspotter

Create CVA grid from a gravity or topography grid

hotspotter

Create CVA grid from seamount locations

originater

Associate seamounts with nearest hotspot point sources

polespotter

Find stage poles given fracture zones and abyssal hills

rotconverter

Manipulate total reconstruction and stage rotations

rotsmoother

Get mean rotations and covariance matrices from set of finite rotations

windbarbs

psbarb

Plot wind barbs in 2-D and 3-D

grdbarb

Plot wind barb field from two component grids

x2sys

x2sys_binlist

Create bin index listing from track data files

x2sys_cross

Calculate crossovers between track data files

x2sys_datalist

Extract content of track data files

x2sys_get

Get track listing from track index database

x2sys_init

Initialize a new x2sys track database

x2sys_list

Extract subset from crossover data base

x2sys_merge

Merge an updated COEs table (smaller) into the main table (bigger)

x2sys_put

Update track index database from track bin file

x2sys_report

Report statistics from crossover data base

x2sys_solve

Determine least-squares systematic correction from crossovers