Skip to content

Commit

Permalink
Update deprecated -JG syntax (#1659)
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelgrund authored Dec 15, 2021
1 parent 387887b commit 8a6ee2e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 16 deletions.
31 changes: 16 additions & 15 deletions examples/projections/azim/azim_general_perspective.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,22 @@
point in space. In a full view of the earth one third of its surface area can
be seen.
**g**\ *lon0/lat0*\ */altitude*\ */azimuth*\ */tilt*\ */twist*\ */Width*\
*/Height*\ */scale*
or **G**\ *lon0/lat0*\ */altitude*\ */azimuth*\ */tilt*\ */twist*\ */Width*\
*/Height*\ */width*
**g**\ *lon0/lat0*\ */scale*\ [**+a**\ *azimuth*]\
[**+t**\ *tilt*]\ [**+v**\ *vwidth/vheight*]\ [**+w**\ *twist*]\
[**+z**\ *altitude*] or **G**\ *lon0/lat0*\ */width*\
[**+a**\ *azimuth*]\ [**+t**\ *tilt*]\ [**+v**\ *vwidth/vheight*]\
[**+w**\ *twist*]\ [**+z**\ *altitude*]
The projection type is set with **g** or **G**.
*lon0/lat0* specifies the projection center and *altitude* sets the height
in km of the viewpoint above local sea level (If altitude is less than 10,
then it is the distance from the center of the earth to the viewpoint in earth
radii). With *azimuth* the direction (in degrees) in which you are looking is
specified, measured clockwise from north. *tilt* is given in degrees and is the
viewing angle relative to zenith. A tilt of 0° is looking straight down, 60° is
looking 30° above horizon. *twist* is the clockwise rotation of the image (in
degrees). *Width* and *Height* describe the viewport angle in degrees, and
*scale* or *width* determine the size of the figure.
The projection type is set with **g** or **G**. *lon0/lat0* specifies the
projection center and *scale* or *width* determine the size of the figure.
With **+a**\ *azimuth* the direction (in degrees) in which you are looking is
specified, measured clockwise from north. **+t**\ *tilt* is given in degrees
and is the viewing angle relative to zenith. A tilt of 0° is looking straight
down, 60° is looking 30° above horizon. The viewport angle in degrees is
described via **+v**\ *vwidth/vheight* and **+w**\ *twist* is the clockwise
rotation of the image (in degrees). **+z**\ *altitude* sets the height in km
of the viewpoint above local sea level (If altitude is less than 10, then it is
the distance from the center of the earth to the viewpoint in earth radii).
The example shows the coast of Northern Europe viewed from 250 km above sea
level looking 30° from north at a tilt of 45°. The height and width of the
Expand All @@ -30,7 +31,7 @@

fig = pygmt.Figure()
fig.coast(
projection="G4/52/250/30/45/0/60/60/12c",
projection="G4/52/12c+a30+t45+v60/60+w0+z250",
region="g",
frame=["x10g10", "y5g5"],
land="gray",
Expand Down
3 changes: 2 additions & 1 deletion examples/projections/table/README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ The below table shows the projection codes for the 31 GMT projections.
- :doc:`Azimuthal gnomonic </projections/azim/azim_gnomonic>`
* - **G**\ |lon0|/|lat0|\ [/\ *horizon*]/\ *width*
- :doc:`Azimuthal orthographic </projections/azim/azim_orthographic>`
* - **G**\ |lon0|/|lat0|/\ *alt*/*azim*/*tilt*/*twist*/*W*/*H*/*width*
* - **G**\ |lon0|/|lat0|\ */width*\[**+a**\ *azimuth*]\ [**+t**\ *tilt*]\
[**+v**\ *vwidth/vheight*]\ [**+w**\ *twist*]\ [**+z**\ *altitude*]
- :doc:`General perspective </projections/azim/azim_general_perspective>`
* - **H**\ [|lon0|/]\ *width*
- :doc:`Hammer equal area </projections/misc/misc_hammer>`
Expand Down

0 comments on commit 8a6ee2e

Please sign in to comment.