X Tutup
Skip to content

Auto-scaling of extent not working for subplots when using sharex and sharey #1325

@michaelaye

Description

@michaelaye

Using MPL 1.1.0 from the 32-bit EPD 7.3-2 on a Macbook Pro Retina.

This error only shows when using subplots. When creating your own sublots via add_subplot it does not seem to occur.

from matplotlib.pyplot import show, subplots
from numpy import arange, array

arr = arange(10000).reshape(100,100)
l = [arr,arr,arr,arr]
narr = array(l)

fig, axes = subplots(2,2,sharex=True,sharey=True)

for ax,im in zip(axes.flatten(),narr):
    ax.imshow(im)

show()

Expected vs Seen:

One can see that all the 4 axes show the image array with an extent of [-10,110, 0, 100] here instead of the expected intent of [0,100, 0, 100].

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      X Tutup