Skip to content

Commit

Permalink
region can be a string type
Browse files Browse the repository at this point in the history
  • Loading branch information
seisman committed May 27, 2024
1 parent 7369cba commit 9c2ac53
Show file tree
Hide file tree
Showing 12 changed files with 35 additions and 35 deletions.
6 changes: 3 additions & 3 deletions pygmt/datasets/earth_age.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def load_earth_age(
resolution: Literal[
"01d", "30m", "20m", "15m", "10m", "06m", "05m", "04m", "03m", "02m", "01m"
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel"] = "gridline",
):
r"""
Expand Down Expand Up @@ -57,8 +57,8 @@ def load_earth_age(
arc-minutes.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration.
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/earth_free_air_anomaly.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def load_earth_free_air_anomaly(
resolution: Literal[
"01d", "30m", "20m", "15m", "10m", "06m", "05m", "04m", "03m", "02m", "01m"
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
):
r"""
Expand Down Expand Up @@ -57,8 +57,8 @@ def load_earth_free_air_anomaly(
arc-minutes.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/earth_geoid.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def load_earth_geoid(
resolution: Literal[
"01d", "30m", "20m", "15m", "10m", "06m", "05m", "04m", "03m", "02m", "01m"
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel"] = "gridline",
):
r"""
Expand Down Expand Up @@ -50,8 +50,8 @@ def load_earth_geoid(
arc-minutes.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration.
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/earth_magnetic_anomaly.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def load_earth_magnetic_anomaly(
resolution: Literal[
"01d", "30m", "20m", "15m", "10m", "06m", "05m", "04m", "03m", "02m"
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
data_source: Literal["emag2", "emag2_4km", "wdmam"] = "emag2",
):
Expand Down Expand Up @@ -71,8 +71,8 @@ def load_earth_magnetic_anomaly(
``data_source="wdmam"``.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
4 changes: 2 additions & 2 deletions pygmt/datasets/earth_mask.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def load_earth_mask(
"30s",
"15s",
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel"] = "gridline",
):
r"""
Expand Down Expand Up @@ -62,7 +62,7 @@ def load_earth_mask(
arc-minutes, and arc-seconds.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*].
*ymin*, *ymax*] or an ISO country code.
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration.
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/earth_relief.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def load_earth_relief(
"03s",
"01s",
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
data_source: Literal["igpp", "gebco", "gebcosi", "synbath"] = "igpp",
use_srtm: bool = False,
Expand Down Expand Up @@ -78,8 +78,8 @@ def load_earth_relief(
arc-minutes, and arc-seconds.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/earth_vertical_gravity_gradient.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def load_earth_vertical_gravity_gradient(
resolution: Literal[
"01d", "30m", "20m", "15m", "10m", "06m", "05m", "04m", "03m", "02m", "01m"
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
):
r"""
Expand Down Expand Up @@ -57,8 +57,8 @@ def load_earth_vertical_gravity_gradient(
arc-minutes.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/mars_relief.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def load_mars_relief(
"15s",
"12s",
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
):
r"""
Expand Down Expand Up @@ -69,8 +69,8 @@ def load_mars_relief(
arc-minutes and arc-seconds.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/mercury_relief.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def load_mercury_relief(
"01m",
"56s",
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
):
r"""
Expand Down Expand Up @@ -67,8 +67,8 @@ def load_mercury_relief(
arc-minutes and arc-seconds.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/moon_relief.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def load_moon_relief(
"15s",
"14s",
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
):
r"""
Expand Down Expand Up @@ -69,8 +69,8 @@ def load_moon_relief(
arc-minutes and arc-seconds.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/pluto_relief.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def load_pluto_relief(
"01m",
"52s",
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel", None] = None,
):
r"""
Expand Down Expand Up @@ -67,8 +67,8 @@ def load_pluto_relief(
arc-minutes and arc-seconds.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration. Default is ``None``, means
Expand Down
6 changes: 3 additions & 3 deletions pygmt/datasets/venus_relief.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def load_venus_relief(
resolution: Literal[
"01d", "30m", "20m", "15m", "10m", "06m", "05m", "04m", "03m", "02m", "01m"
] = "01d",
region: Sequence[float] | None = None,
region: Sequence[float] | str | None = None,
registration: Literal["gridline", "pixel"] = "gridline",
):
r"""
Expand Down Expand Up @@ -56,8 +56,8 @@ def load_venus_relief(
arc-minutes.
region
The subregion of the grid to load, in the form of a sequence [*xmin*, *xmax*,
*ymin*, *ymax*]. Required for grids with resolutions higher than 5 arc-minutes
(i.e., ``"05m"``).
*ymin*, *ymax*] or an ISO country code. Required for grids with resolutions
higher than 5 arc-minutes (i.e., ``"05m"``).
registration
Grid registration type. Either ``"pixel"`` for pixel registration or
``"gridline"`` for gridline registration.
Expand Down

0 comments on commit 9c2ac53

Please sign in to comment.