Skip to content

Commit 0e18bab

Browse files
committed
Stop parsing step 'where' keyword (fixes #359)
1 parent ab6affd commit 0e18bab

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

Diff for: WHATSNEW.rst

+2
Original file line numberDiff line numberDiff line change
@@ -229,6 +229,8 @@ Bug fixes
229229
but `boxpctile` is due to typo (:issue:`382`).
230230
* Fix issue where list-of-string colors passed to `~proplot.axes.Axes.scatter`
231231
are interpreted as data values (:issue:`316`).
232+
* Fix issue where `~proplot.axes.PlotAxes.step` `where` parameter is ignored due
233+
to `drawstyle` conversion (:issue:`359`).
232234
* Fix issue where *x* and *y* axis limits are reversed when passing to
233235
`~proplot.axes.PlotAxes.hexbin` and `~proplot.axes.PlotAxes.hist2d` (:issue:`334`).
234236
* Fix regression where *x* or *y* axis limits are reversed when passing to

Diff for: proplot/axes/plot.py

+1-5
Original file line numberDiff line numberDiff line change
@@ -2909,7 +2909,7 @@ def plotx(self, *args, **kwargs):
29092909
kwargs = _parse_vert(default_vert=False, **kwargs)
29102910
return self._apply_plot(*args, **kwargs)
29112911

2912-
def _apply_step(self, *pairs, vert=True, where='pre', **kwargs):
2912+
def _apply_step(self, *pairs, vert=True, **kwargs):
29132913
"""
29142914
Plot the steps.
29152915
"""
@@ -2918,11 +2918,7 @@ def _apply_step(self, *pairs, vert=True, where='pre', **kwargs):
29182918
# approach... but instead repeat _apply_plot internals here so we can
29192919
# disable error indications that make no sense for 'step' plots.
29202920
kws = kwargs.copy()
2921-
opts = ('pre', 'post', 'mid')
2922-
if where not in opts:
2923-
raise ValueError(f'Invalid where={where!r}. Options are {opts!r}.')
29242921
kws.update(_pop_props(kws, 'line'))
2925-
kws.setdefault('drawstyle', 'steps-' + where)
29262922
kws, extents = self._inbounds_extent(**kws)
29272923
objs = []
29282924
for xs, ys, fmt in self._iter_arg_pairs(*pairs):

0 commit comments

Comments
 (0)