Skip to content

Add another gallery example for inset #1018

Closed

Description

@seisman

Currently, we already have a good and nice inset example at https://www.pygmt.org/v0.3.0/gallery/plot/inset.html. This example doesn't cover all use cases of insets.

Another common use case is plotting a rectangle in the inset map to show the area of the main figure. Below is an example (originally from https://docs.gmt-china.org/latest/tutorial/inset/):

image

The corresponding bash script is:

#!/usr/bin/env bash
gmt begin inset-map png,pdf
    gmt coast -R139.2/140.5/34.8/36 -JM12c -Baf -BWSne -W2p -A1000 -Glightbrown -Sazure1 --FORMAT_GEO_MAP=dddF
    gmt inset begin -DjBL+w3c/3.6c+o0.1c -F+gwhite+p1p
        gmt coast -R129/146/30/46 -JM? -EJP+glightbrown+p0.2p -A10000
        echo 139.2 34.8 140.5 36 | gmt plot -Sr+s -W1p,blue
    gmt inset end
gmt end show

We should add a gallery example for this use case.

Activity

  1. added
    documentation
    help wanted
    on Mar 7, 2021
  2. added this to the 0.3.1 milestone on Mar 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationhelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions