Interface Between GMT Map-Making Software and R

Interface between the GMT map-making software and R, enabling the user to manipulate geographic data within R and call GMT commands to draw and annotate maps in postscript format. The gmt package is about interactive data analysis, rapidly visualizing subsets and summaries of geographic data, while performing statistical analysis in the R console.


o Added NAMESPACE file.

o Changed example to A4 paper.

o Changed -M to -m in psbar.

o Changed -M to -m in psbar.

o Updated maintainer email address.

o Updated URL of GMT manual.

o No user-visible changes.

o Improved psxy(), pstext(), and psclose() so they no longer expect a Mercator-projected map, but any kind of map.

o Simplified gmt.system(), thanks to improved system() in R 2.5.0.

o Added function num2deg() to convert numeric to degrees, the opposite of deg2num().

o Changed gmt() so quiet=TRUE by default, and files .gmtcommands4 and .gmtdefaults4 are created in dirname(file) instead of R working directory.

o Changed psxy(), pstext(), and psbar() so temporary GMT input files are saved directory dirname(tempdir()) instead of R working directory. These temporary files are later removed by psclose().

o Changed psclose() so the bounding box declaration is moved to the postscript file header, and GMT input files are removed from temporary directory. If cleanup=TRUE, the files .gmtcommands4 and .gmtdefaults4 are also removed.

o Improved r2gmt() to support # commented table header.

o Added scripts example.bat and that mimic the behaviour of the 'gmt' package.

o Improved help page examples.

o Improved help pages.

o Added function gmt.system() to handle the interface between R and system commands, passing invisible=TRUE on operating systems that support that argument.

o Improved performance by changing approach from shell("cmd>file") to ps<-system("cmd");writeLines(ps,file). Demo runs four times faster.

o Added help pages for all functions.

o Submitted to CRAN.

o Added argument 'ref' to psbar() to standardize bar height.

o Added function gmt() to initialize GMT session, making .gmthome(), gmtdefaults, and gmtset() obsolete. The package assumes that binaries are in the PATH and GMTHOME is defined.

o Added function r2gmt() to write GMT input files, making .data2gmt() and .file2gmt() obsolete.

o Added functions .data2gmt(), .file2gmt(), .gmthome(), deg2num(), geodist(), gmt(), gmtdefaults(), gmtset(), psbar(), psclose(), pscoast(), pstext(), and psxy().

o Added example objects, demo.coast, demo.set, demo.text, and demo.xy.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


2.0-1 by Arni Magnusson, 8 days ago

Browse source code at

Authors: Arni Magnusson [aut, cre]

Documentation:   PDF Manual  

Task views: Analysis of Spatial Data

GPL (>= 2) license

Imports utils

System requirements: gmt

Imported by vmsbase.

See at CRAN