<!--To help us understand and resolve your issue, please fill out the form to the best of your ability.--> <!--You can feel free to delete the sections that do not apply.--> ### Bug report **Bug summary** <!--A short 1-2 sentences that succinctly describes the bug--> Setting the yscale to log in histogram results in empty plot **Code for reproduction** <!--A minimum code snippet required to reproduce the bug, also minimizing the number of dependencies required--> ```python import numpy as np import matplotlib as mpl import matplotlib.pyplot as plt plt.figure() plt.hist(np.random.normal(size=1000)) plt.yscale('log') plt.show() ``` **Actual outcome**  <!--The output produced by the above code, which may be a screenshot, console output, etc.--> **Expected outcome**  <!--A description of the expected outcome from the code snippet--> <!--If this used to work in an earlier version of Matplotlib, please note the version it used to work on--> **Matplotlib version** <!--Please specify your platform and versions of the relevant libraries you are using:--> * Operating System: Archlinux * Matplotlib Version: 2.1.0rc1+49.g20aff4baa * Python Version: 3.6 * Jupyter Version (if applicable): notebook 5.1 * Other Libraries: <!--Please tell us how you installed matplotlib and python e.g., from source, pip, conda--> <!--If you installed from conda, please specify which channel you used if not the default-->
Activity
tacaswell commentedon Sep 28, 2017
plt.yscale('log', nonposy='clip')will show the histogram on the log scale.tacaswell commentedon Sep 28, 2017
This was changed in dda42ab / #8836 and document http://matplotlib.org/devdocs/api/api_changes.html#default-behavior-of-log-scales-changed-to-mask-0-values.
weninc commentedon Sep 28, 2017
ah yes that works. Wasn't aware of the change
tacaswell commentedon Sep 28, 2017
No worries!