Skip to content

Dotted grid lines in v2.0.0b1 #6515

@rayosborn

Description

@rayosborn

After installing v2.0.0b1 into my conda installation (Mac OS X 10.11.5, Python 2.7.11, Anaconda 2.3.0), I noticed a subtle problem with dotted lines in grids. I used the following code to generate the two attached images in v1.5.1 and v2.0.0b1, respectively:

import numpy as np
import matplotlib.pyplot as plt

x = np.array([1, 1, 1, 2, 2, 2, 3, 3, 3])
y = np.array([1, 2, 3, 1, 2, 3, 1, 2, 3])
a = np.array([1, 2, 3, 4, 5, 6, 7, 8, 9])
grid = a.reshape(3, 3)

plt.imshow(grid, extent=(x.min(), x.max(), y.min(), y.max()),interpolation='bicubic')
plt.grid(linestyle='dotted')
plt.show()

If you blow up the new image, alternate dots are linked by a faint gray line, whereas the old dots are clearly separated. Overlaid on some plots, this can make the gridlines look more like dashed lines.
old-matplotlib-grid
new-matplotlib-grid

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