• Stars
    star
    193
  • Rank 199,907 (Top 4 %)
  • Language
    Julia
  • License
    Other
  • Created over 10 years ago
  • Updated 28 days ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Generic Mapping Tools Library Wrapper for Julia

GMT.jl

Julia wrapper for the Generic Mapping Tools GMT

Documentation Build Status (Julia 1.8) Discourse Forum Collaboration

The Generic Mapping Tools, GMT, is an open source collection of tools for manipulating geographic and Cartesian data sets (including filtering, trend fitting, gridding, projecting, etc.) and producing PostScript illustrations ranging from simple x–y plots via contour maps to artificially illuminated surfaces and 3D perspective views. This link will take you to an impressive collection of figures made with GMT

This wrapper works with GMT6.4.0 and above and it is intended not only to access to GMT from within the Julia language but also to provide a more modern interface to the GMT modules. For example, instead of using the GMT classic syntax to do a line plot:

gmt psxy filename -R0/10/0/5 -JX12 -W1p -Ba -P > psfile.ps

one can simply do:

plot("filename", show=true)

or, more verbose but easier to read

coast(region=:global, proj=:Winkel, frame=:g, area=10000,
      land=:burlywood4, water=:wheat1, show=true)

instead of

gmt coast -Rd -JR12 -Bg -Dc -A10000 -Gburlywood4 -Swheat1 -P > GMT_winkel.ps

to show

Install

] add GMT

A word about the installation. On Unix (Mac included) we now use a GMT_jll artifact to provide the GMT binary, but for Windows we keep using a MSVC GMT binary. This means that on Windows the GMT (the C lib) is not updated automatically (but GMT.jl is). Updates there are done manually by running upGMT(). Also, for some reasons it may be desirable to use a system wide GMT installation. To swap to a system wide GMT installation, do (in REPL):

  • ENV["SYSTEMWIDE_GMT"] = 1;
  • import Pkg; Pkg.build("GMT")
  • restart Julia

Note the above will work up until some other reason triggers a Julia recompile, where the JLL artifacts will be used again. To make the ENV["SYSTEMWIDE_GMT"] = 1 solution permanent, declare a "SYSTEMWIDE_GMT" environment variable permanently in your .bashrc (or whatever).

Using

The GMT Julia wrapper was designed to work in a way the close as possible to the command line version and yet to provide all the facilities of the Julia language. In this sense, all GMT options are put in a single text string that is passed, plus the data itself when it applies, to the gmt() command. However, we also acknowledge that not every one is comfortable with the GMT syntax. This syntax is needed to accommodate the immense pool of options that let you control all details of a figure but that also makes it harder to read/master.

To make life easier we provide also a new mechanism that use the GMT module name directly and where the program's options are set via keyword arguments. While the monolotic way of using this package is robust and keeps being updated to latestes GMT developments, this By modules alternative is a Work in Progress (several of the GMT supplements were not ported yet) and some things may not work yet. So all help is most than wellcome.

Documentation and Examples

Credits

A lot of the GDAL interface functions rely on code from GDAL.jl by Martijn Visser and ArchGDAL.jl by Yeesian Ng, released under the MIT license.

License

The GMT.jl is free software: you can redistribute it and/or modify it under the terms of the MIT "Expat" License. A copy of this license is provided in LICENSE.txt

More Repositories

1

gmt

The Generic Mapping Tools
C
834
star
2

pygmt

A Python interface for the Generic Mapping Tools.
Python
744
star
3

gmtmex

GMT API for MATLAB
MATLAB
41
star
4

try-gmt

Try GMT, PyGMT, and GMT.jl online! All in one place!
Jupyter Notebook
41
star
5

gmt-for-geodesy

Material for the annual GMT for EarthScope short course
Jupyter Notebook
33
star
6

2020-unavco-course

Planning and material for the 2020 UNAVCO GMT for Geodesy course
Shell
33
star
7

egu22pygmt

Crafting beautiful maps with PyGMT at EGU22
Jupyter Notebook
32
star
8

2021-unavco-course

Planning and material for the 2021 UNAVCO GMT for Geodesy course
Shell
28
star
9

2019-unavco-course

Material for the 2019 UNAVCO Short Course "The Generic Mapping Tools for Geodesy"
Shell
21
star
10

gshhg-gmt

Scripts and raw data that combine to produce the GSHHG data sets for GMT
C
20
star
11

RemoteS.jl

Remote sensing data processing
Julia
18
star
12

foss4g2019oceania

PyGMT Workshop at FOSS4G Oceania 2019, Wellington, New Zealand
Jupyter Notebook
14
star
13

website

A front page for the GMT project
HTML
10
star
14

sphinx_gmt

Sphinx extensions for GMT
Python
7
star
15

gmtserver-admin

Cache data and script for managing the GMT data server
Shell
7
star
16

dcw-gmt

Data and scripts that maintain and build the DCW data used in GMT
Shell
7
star
17

remote-datasets

Documentation for remote datasets on the GMT server
Shell
5
star
18

GMTjl_doc

GMT.jl documentation site
HTML
5
star
19

try-gmt-python

A Jupyter notebook demo of the latest GMT/Python. Runs on mybinder.org.
Jupyter Notebook
4
star
20

2021-eswn-pygmt-workshop

A workshop on open source development
Jupyter Notebook
4
star
21

gmt-examples

Tutorials and guides for the Generic Mapping Tools
4
star
22

genericmappingtools.github.io

Built HTML for the GMT website. DO NOT COMMIT DIRECTLY HERE
HTML
3
star
23

scipy2021

PyGMT tutorial submission for SciPy 2021
3
star
24

agu24workshop

Mastering Geospatial Visualizations with GMT/PyGMT pre-conference workshop at AGU24
3
star
25

gmtmodernize

Tool to convert GMT scripts to the new "modern" mode
Python
2
star
26

gsrasterize

Play code to attempt to convert PS directly to Ghotscript formats without saving intermediate files to disk.
C
2
star
27

gmt6demo

A demo of new features in GMT6. Uses Jupyter notebooks and runs online on mybinder.org (no install required).
Jupyter Notebook
2
star
28

gmt-rpm

RPM specfiles for the Fedora Copr build system
2
star
29

.github

Community files
1
star
30

custom-supplements

How to make custom GMT supplements
PostScript
1
star
31

building-wrappers

Documentation and discussion about building wrappers for GMT
1
star
32

oversight

Reports and planning documents for the GMT Steering Committee
1
star
33

gmt-fortran

GMT API for FORTRAN
Fortran
1
star
34

gmt-2024-animation

Illustration and movie scripts for 2024 publication on GMT animations
Shell
1
star