diff --git a/doc/install.rst b/doc/install.rst index 67b803b9e5d..0a529d84491 100644 --- a/doc/install.rst +++ b/doc/install.rst @@ -30,20 +30,16 @@ Which GMT? PyGMT requires Generic Mapping Tools (GMT) version 6 as a minimum, which is the latest released version that can be found at -`this website `__. - +the `GMT official site `__. We need the latest GMT (>=6.0.0) since there are many changes being made to GMT itself in response to the development of PyGMT, mainly the new `modern execution mode `__. -Compiled conda packages of GMT for Linux and Mac are provided through +Compiled conda packages of GMT for Linux, macOS and Windows are provided through `conda-forge `__. Advanced users can also `build GMT from source `__ instead, which is not so recommended but we would love to get feedback from anyone who tries. -For Windows, conda GMT packages are available, but they do not currently work with PyGMT, -so users will need to build from source or use the Windows Subsystem for Linux, see -`here `__ for more details. We recommend following the instructions further on to install GMT 6. @@ -55,6 +51,7 @@ PyGMT requires the following libraries: * `numpy `__ * `pandas `__ * `xarray `__ +* `netCDF4 `__ * `packaging `__ The following are optional (but recommended) dependencies: @@ -79,7 +76,7 @@ First, we must configure conda to get packages from the Now we can create a new conda environment with Python and all our dependencies installed (we'll call it ``pygmt`` but you can change it to whatever you want):: - conda create --name pygmt python=3.6 pip numpy pandas xarray packaging gmt=6.0.0 + conda create --name pygmt python=3.8 pip numpy pandas xarray netcdf4 packaging gmt Activate the environment by running:: @@ -88,17 +85,16 @@ Activate the environment by running:: From now on, all commands will take place inside the conda virtual environment and won't affect your default installation. -.. note:: - - **Currently, this has only been tested to work on Linux and macOS.** - We don't have tests running on Windows yet, so things might be broken. - Please report any errors by `creating an issue on Github `__. Installing PyGMT ---------------- -Now that you have GMT installed and your conda environment activated, -use ``pip`` to install the latest release of PyGMT from `PyPI `__:: +Now that you have GMT installed and your conda environment activated, you can +use ``conda`` to install the latest release of PyGMT from `conda-forge `__:: + + conda install pygmt + +or use ``pip`` to install from `PyPI `__:: pip install pygmt @@ -134,7 +130,11 @@ This can happen if you have multiple versions of GMT installed. You can tell PyGMT exactly where to look for ``libgmt`` by setting the ``GMT_LIBRARY_PATH`` environment variable. This should be set to the directory where ``libgmt.so``, ``libgmt.dylib`` or ``gmt.dll`` -can be found for Linux, MacOS and Windows respectively. +can be found for Linux, macOS and Windows respectively. e.g. in a terminal run:: - export GMT_LIBRARY_PATH=$HOME/anaconda3/envs/pygmt/lib + # Linux/macOS + export GMT_LIBRARY_PATH=$HOME/anaconda3/envs/pygmt/lib + # Windows + set "GMT_LIBRARY_PATH=C:\Users\USERNAME\Anaconda3\envs\pygmt\Library\bin\" + diff --git a/pygmt/base_plotting.py b/pygmt/base_plotting.py index 0a1581f258d..06d4dd43bd5 100644 --- a/pygmt/base_plotting.py +++ b/pygmt/base_plotting.py @@ -349,6 +349,8 @@ def grdview(self, grid, **kwargs): Full option list at :gmt-docs:`grdview.html` + {aliases} + Parameters ---------- grid : str or xarray.DataArray @@ -399,7 +401,6 @@ def grdview(self, grid, **kwargs): ``'[x|y|z]azim[/elev[/zlevel]][+wlon0/lat0[/z0]][+vx0/y0]'``. Select perspective view. - {aliases} """ kwargs = self._preprocess(**kwargs) kind = data_kind(grid, None, None) diff --git a/pygmt/sampling.py b/pygmt/sampling.py index 4ed2a6d171b..8b6ba7b45d1 100644 --- a/pygmt/sampling.py +++ b/pygmt/sampling.py @@ -51,6 +51,7 @@ def grdtrack(points, grid, newcolname=None, outfile=None, **kwargs): ------- track: pandas.DataFrame or None Return type depends on whether the outfile parameter is set: + - pandas.DataFrame table with (x, y, ..., newcolname) if outfile is not set - None if outfile is set (track output will be stored in outfile)