Skip to content

Commit

Permalink
refactor: change module name from profile to profiles to match pl…
Browse files Browse the repository at this point in the history
…ural style of other modules.

BREAKING CHANGE: please update all import statements to use `profiles` instead of `profile`!
  • Loading branch information
mdtanker committed Jun 14, 2024
1 parent f374dd2 commit 84524e3
Show file tree
Hide file tree
Showing 13 changed files with 1,764 additions and 1,756 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ exclude: |
docs/api/polartoolkit.rst|
docs/api/polartoolkit.fetch.rst|
docs/api/polartoolkit.maps.rst|
docs/api/polartoolkit.profile.rst|
docs/api/polartoolkit.profiles.rst|
docs/api/polartoolkit.regions.rst|
docs/api/polartoolkit.utils.rst|
docs/_polartoolkit_refs.bib|
Expand Down
6 changes: 0 additions & 6 deletions docs/api/polartoolkit.profile.rst

This file was deleted.

6 changes: 6 additions & 0 deletions docs/api/polartoolkit.profiles.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
polartoolkit.profiles
--------------------
.. automodule:: polartoolkit.profiles
:members:
:undoc-members:
:show-inheritance:
2 changes: 1 addition & 1 deletion docs/api/polartoolkit.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ API Reference

polartoolkit.fetch
polartoolkit.maps
polartoolkit.profile
polartoolkit.profiles
polartoolkit.regions
polartoolkit.utils
2 changes: 1 addition & 1 deletion docs/gallery/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ subplot_layout

## Profiles

Here are some examples for use the module `Profile`.
Here are some examples for use the module `Profiles`.

```{nbgallery}
---
Expand Down
71 changes: 36 additions & 35 deletions docs/how_to/profiles.ipynb

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Create high-quality maps using PyGMT with functions specifically tailored to
Antarctica (and soon to include Greenland and the Arctic). plot types: 2D, 3D,
subplots, interactive maps

### Profile
### Profiles

Define a line, sample layers & data along it, and plot the results.

Expand Down
10 changes: 5 additions & 5 deletions docs/quickstart.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 7,
"metadata": {
"execution": {
"iopub.execute_input": "2024-02-09T04:53:05.977192Z",
Expand All @@ -29,7 +29,7 @@
},
"outputs": [],
"source": [
"from polartoolkit import fetch, maps, profile, regions"
"from polartoolkit import fetch, maps, profiles, regions"
]
},
{
Expand Down Expand Up @@ -129,7 +129,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"Define a profile between two points and plot a cross section of ice, ocean, and earth layers between them using the `profile` module. "
"Define a profile between two points and plot a cross section of ice, ocean, and earth layers between them using the `profiles` module. "
]
},
{
Expand Down Expand Up @@ -164,7 +164,7 @@
"a = (1925000, 830000)\n",
"b = (2200000, 600000)\n",
"\n",
"fig, _, _ = profile.plot_profile(\n",
"fig, _, _ = profiles.plot_profile(\n",
" method=\"points\",\n",
" start=a,\n",
" stop=b,\n",
Expand All @@ -190,7 +190,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.1.-1"
"version": "3.11.9"
},
"vscode": {
"interpreter": {
Expand Down
10 changes: 5 additions & 5 deletions docs/tutorial/cross_sections_and_profiles.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"source": [
"import os\n",
"\n",
"from polartoolkit import profile"
"from polartoolkit import profiles"
]
},
{
Expand Down Expand Up @@ -72,7 +72,7 @@
"a = (1925000, 830000)\n",
"b = (2200000, 600000)\n",
"\n",
"fig, _, _ = profile.plot_profile(\n",
"fig, _, _ = profiles.plot_profile(\n",
" method=\"points\",\n",
" start=a,\n",
" stop=b,\n",
Expand Down Expand Up @@ -115,7 +115,7 @@
}
],
"source": [
"fig, _, _ = profile.plot_profile(\n",
"fig, _, _ = profiles.plot_profile(\n",
" method=\"points\",\n",
" start=a,\n",
" stop=b,\n",
Expand Down Expand Up @@ -152,7 +152,7 @@
}
],
"source": [
"fig, _ = profile.plot_data(\n",
"fig, _ = profiles.plot_data(\n",
" method=\"points\",\n",
" start=a,\n",
" stop=b,\n",
Expand Down Expand Up @@ -196,7 +196,7 @@
}
],
"source": [
"fig, _, _ = profile.plot_profile(\n",
"fig, _, _ = profiles.plot_profile(\n",
" method=\"points\",\n",
" start=a,\n",
" stop=b,\n",
Expand Down
Loading

0 comments on commit 84524e3

Please sign in to comment.