We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent de0eba8 commit 6e80ed1Copy full SHA for 6e80ed1
pygmt/src/xyz2grd.py
@@ -10,6 +10,26 @@
10
11
__doctest_skip__ = ["xyz2grd"]
12
13
+def _xyz2xyz(x=None, y=None, z=None):
14
+ if x is not None:
15
+ x = np.atleast_1d(x)
16
+ if y is not None:
17
+ y = np.atleast_1d(y)
18
+ if z is not None:
19
+ z = np.atleast_1d(z)
20
+
21
+ # Three 1-D arrays.
22
+ if x.ndim == 1 and y.ndim == 1 and z.ndim == 1:
23
+ pass
24
+ # z is a 2-D array.
25
+ if z.ndim == 2:
26
+ if x is None:
27
+ x = np.arange(z.shape[0])
28
+ if y is None:
29
+ y = np.arange(z.shape[1])
30
+ return
31
+ return x, y, z
32
33
34
@fmt_docstring
35
@use_alias(
0 commit comments