Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

shared twinned subplots: supportax.twinx(sharey=...) /ax.twiny(sharex=...) #8392

Closed
Labels
status: inactiveMarked by the “Stale” Github Action
@anntzer

Description

@anntzer

After

fig, (ax1, ax2) = plt.subplots(2, sharex=True, sharey=True)ax1.plot([1, 2]); ax2.plot([1, 2])ax1.twinx().plot([2, 1]); ax2.twinx().plot([2, 1])

zooming/panning one of the subplots only affects the other subplot along the x axis, but not the y axis -- because zooming/panning affects the twinned subplots, which only share their x axis, whereas the y sharing is lost (of course, it cannot always be shared with the original subplots -- the sharing needs to occur directly between the twinned subplots).

Having thought approximately 30s about the issue, I believe an easy way out would be to support passing an explicitshare{y,x} argument totwin{x,y} (for the "other" axis, as the twinned axis is already shared with the original subplot, of course), so that one can properly re-link the twinned subplots between themselves.

Metadata

Metadata

Assignees

No one assigned

    Labels

    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


      [8]ページ先頭

      ©2009-2025 Movatter.jp