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

Appearance settings

Get ticklabels back on shared axis #10911

Copy link
Copy link
Closed
@ImportanceOfBeingErnest

Description

Bug report

Bug summary

When sharing the axes through plt.subplots(2, sharex=True) the ticklabels on the upper axes are rightfully suppressed. However, in many cases you may still want/need to show them.

Im matplotlib 2.0.2 this was easily possible by turning them visible again. This is not possible any more with matplotlib 2.2.

Code for reproduction

import matplotlib.pyplot as plt

fig, (ax,ax2) = plt.subplots(2, sharex=True)

plt.setp(ax.get_xticklabels(),visible=True)

plt.show()

Actual outcome in matplotlib 2.2.2

image

Expected outcome, actual outcome in matplotlib 2.0.2

I would expect matplotlib not to break the previously working solution of turning the labels visible. The expected outcome would be, as in version 2.0.2 to see the ticklabels on the upper axes.

image

pharshalp, akiross, vastol, Eli-Notes, marcelovilla and 7 moretahaum

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.