Skip to content

Inconsistent kwarg naming between step() and fill_between() #15085

Closed as not planned

Description

@andrzejnovak

Calling step style is using a different kwarg name in step() and `fill_between() i.e.

ax.step(x, y, where='post')

and

ax.fill_between(x, y, step='post')

Maybe use step in both or pick a better kwarg name usable in both and not conflicting with where in fill_between which turns bin filling on/off

Activity

  1. added
    API: consistencyConsistency of the matplotlib API, including naming, behavior, defaults, …
    on Aug 19, 2019
  2. andrzejnovak commented on Aug 27, 2019

    @andrzejnovak
    ContributorAuthor

    Any input on renaming, while I'm working on #15065 ? Maybe sync step() to fill_between() and add the same where() kwarg for skipping segments?

  3. timhoffm commented on Mar 25, 2020

    @timhoffm
    Member

    This should also be consistent with

    ax.plot(x, y, drawstyle='step-post')
    

    Maybe we should

    ax.fill_between(x, y, drawstyle='step-post')
    

    But then again, is it worth the deprecation?

    ax.step is just a thin wrapper around plot, setting the drawstyle. It must have a straight-forward parameter name. I'd leave where.

  4. github-actions commented on Jun 28, 2023

    @github-actions

    This issue has been marked "inactive" because it has been 365 days since the last comment. If this issue is still present in recent Matplotlib releases, or the feature request is still wanted, please leave a comment and this label will be removed. If there are no updates in another 30 days, this issue will be automatically closed, but you are free to re-open or create a new issue if needed. We value issue reports, and this procedure is meant to help us resurface and prioritize issues that have not been addressed yet, not make them disappear. Thanks for your help!

  5. timhoffm commented on Jun 28, 2023

    @timhoffm
    Member

    Let‘s not go through the hassle of an API change. step() is a bit awkward anyway and we nowadays have stairs(), which is preferable in many cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    API: consistencyConsistency of the matplotlib API, including naming, behavior, defaults, …status: inactiveMarked by the “Stale” Github Action

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions