Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

share, span options for twin x and y axes #205

Open
kinyatoride opened this issue Jul 10, 2020 · 1 comment
Open

share, span options for twin x and y axes #205

kinyatoride opened this issue Jul 10, 2020 · 1 comment
Labels
Milestone

Comments

@kinyatoride
Copy link

Description

Hi, I really like the feature that twinx and twiny can be applied to axs, which was not possible with matplotlib.
Would it be possible to add share and span options to twinx and twiny? Such as twinx(sharey=3, spany=True).
Currently, when we specified ylabel for twin axes, it will plot to all axes.

Steps to reproduce

import numpy as np
import proplot as plot

fig, axs = plot.subplots(nrows=2, ncols=2)
axs1 = axs.twinx()

x = np.arange(10)

for ax, ax1 in zip(axs, axs1):
    ax.plot(np.sin(x), c='b')
    ax1.plot(np.cos(x), c='r')
    
axs.format(ycolor='b', ylabel='ylabel1')
axs1.format(ycolor='r', ylabel='ylabel2')

Current behavior:
ylabels and ticks are shown in every plots.
Screen Shot 2020-07-10 at 10 45 00

Proplot version

0.6.4

@lukelbd
Copy link
Collaborator

lukelbd commented Jul 19, 2020

Yep this is a really important item on my to-do list -- you can monitor PR #183 for updates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants