Installing GMT Mapping tools onto Ubuntu.
Thankfully it exists as a package so you can grab it via apt-get. I suggest grabbing the tutorial and examples at the sametime.
sudo apt-get install gmt gmt-examples gmt-tutorial-pdf
Ok, now lets try and run a test. Create the following in a file called
linproj.sh. Personally I have a folder called GMTplotting for this file but you may prefer to arrange it differently.
#!/bin/bash psbasemap -R10/70/-3/8 -JX4i/3i -B10/1:."My first plot": -P > plot.ps
You can now run this script using
./linproj.sh providing it has executable rights if not just type
chmod +x linproj.sh.
Now if you are running certain flavours of unix you will get an error telling you that psbasemap: command not found. This is normal – just add
The second test is to try
psbasemap -R1/10000/1e20/1e25 -JX9il/6il \ -B2:"Wavelength (m)":/a1pf3:"Power (W)":WS > plot.p