Skip to content

Get ticklabels back on shared axis #10911

@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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy