Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to automatically generate an image which highlights a location from a global view.

Here is an example of what I would like to achieve: enter image description here

I am debating using python utilities such as mpl_toolkits.basemap,which examples can be seen here. But I was hoping to find an easier way from you GIS professionals.

This is for a small webpage, and it would be nice to have it automatically generated.

share|improve this question
up vote 2 down vote accepted

I found out how to do it using Generic Mapping Tool.

From the website: GMT is an open source collection of ~65 tools for manipulating geographic and Cartesian data sets (including filtering, trend fitting, gridding, projecting, etc.) and producing Encapsulated PostScript File (EPS) illustrations ranging from simple x-y plots via contour maps to artificially illuminated surfaces and 3-D perspective views; the GMT supplements add another ~70 more specialized tools. GMT supports over 30 map projections and transformations and comes with support data such as GSHHS coastlines, rivers, and political boundaries.

 # -JGlon0/lat0/size(in inches)
 # Define RGB colors after -S and -G (e.g. -S175/200/225)
 pscoast -JG10/20/4i -Rg -P -Sblue -Gtan -K >
 # Symbol shape and size in -Sa0.2i
 # Color in -G
 echo -10 -10 | psxy -J -Rg -P -Sa0.2i -Gred -W1p -O >>
 # The letter after -T determines the kind of raster image (j for JPG, g for PNG
 ps2raster -A -Tj

Will produce this:

enter image description here

Special thanks to Matthew Herman for helping me with this.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.