| 2892 | |
| 2893 | @image_comparison(['hist2d_transpose.png'], remove_text=True, style='mpl20') |
| 2894 | def test_hist2d_transpose(): |
| 2895 | # Remove this line when this test image is regenerated. |
| 2896 | plt.rcParams['pcolormesh.snap'] = False |
| 2897 | |
| 2898 | np.random.seed(0) |
| 2899 | # make sure the output from np.histogram is transposed before |
| 2900 | # passing to pcolorfast |
| 2901 | x = np.array([5]*100) |
| 2902 | y = np.random.randn(100)-2 |
| 2903 | fig, ax = plt.subplots() |
| 2904 | ax.hist2d(x, y, bins=10, rasterized=True) |
| 2905 | |
| 2906 | |
| 2907 | def test_hist2d_density(): |