Skip to content

Commit

Permalink
Figure.plot: Deprecate parameter "columns" to "incols" (remove in v0.…
Browse files Browse the repository at this point in the history
…6.0)

As discussed in #764, this PR replaces the **columns** parameter by **incols** for plot.py and adds the deprecation .
  • Loading branch information
michaelgrund authored May 26, 2021
1 parent f7a9e5e commit 0be992e
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions pygmt/src/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
Y="yshift",
Z="zvalue",
a="aspatial",
i="columns",
i="incols",
l="label",
c="panel",
f="coltypes",
Expand All @@ -45,6 +45,7 @@
)
@kwargs_to_strings(R="sequence", c="sequence_comma", i="sequence_comma", p="sequence")
@deprecate_parameter("sizes", "size", "v0.4.0", remove_version="v0.6.0")
@deprecate_parameter("columns", "incols", "v0.4.0", remove_version="v0.6.0")
def plot(self, x=None, y=None, data=None, size=None, direction=None, **kwargs):
r"""
Plot lines, polygons, and symbols in 2-D.
Expand Down Expand Up @@ -192,10 +193,10 @@ def plot(self, x=None, y=None, data=None, size=None, direction=None, **kwargs):
{a}
{c}
{f}
columns : str or 1d array
incols : str or 1d array
Choose which columns are x, y, color, and size, respectively if
input is provided via *data*. E.g. ``columns = [0, 1]`` or
``columns = '0,1'`` if the *x* values are stored in the first
input is provided via *data*. E.g. ``incols = [0, 1]`` or
``incols = '0,1'`` if the *x* values are stored in the first
column and *y* values in the second one. Note: zero-based
indexing is used.
label : str
Expand Down

0 comments on commit 0be992e

Please sign in to comment.