Open seisman opened 3 years ago
Also should mention that plotting shapefiles directly using plot
and plot3d
(maybe others too?) is supported. Xref #1616 and https://docs.generic-mapping-tools.org/6.3/cookbook/file-formats.html?highlight=shapefile#shapefiles
pathlib.Path
support was added in https://github.com/GenericMappingTools/pygmt/pull/1382.
Working on supporting 3-band xarray.DataArray
inputs at #2590, this would be in addition to regular 1-band xarray.DataArray
inputs (e.g. DEMs).
Inspired by PR #1186.
For GMT CLI, there are mainly two types of input: a table or a grid. PyGMT is more powerful and can accept more input types.
For a table input, PyGMT functions generally accept the following input types:
data="input.dat"
data=data
x
,y
, e.g.,x=5.0, y=5.0
x
andy
, e.g.,x=[1.0, 2.0], y=[3.0, 4.0]
x
andy
, e.g.,x=np.array([1.0, 2.0]), y=np.array([3.0, 4.0])
geopandas.GeoDataFrame
(see #608 & #1000)xarray.Dataset
io.StringIO
(once #576 is done)For a grid input, PyGMT functions generally accept the following input types:
grid="input_grid.nc"
grid=grid
Although these various input data types are already used in different tutorials and examples, I think it would be better to have a standalone tutorial, explaining these input types.