How to zoom in a histogram in seaborn/matplotlib?
<p>I produced a histogram which looks something like this:</p>

<p><a href="http://i.stack.imgur.com/M96Am.png" rel="nofollow"><img src="http://i.stack.imgur.com/M96Am.png" alt="enter image description here"></a></p>

<p>Code that I used to produce this plot:</p>

<pre><code>sns.countplot(table.column_name)
</code></pre>

<p>As you can notice, the entire histogram gets clustered at the left end due to uneven distribution of data.</p>

<p>How do I zoom in at the left end?</p>

<p>One way that I tried and it gave me a marginally better result was :</p>

<pre><code>plt.xlim(0,25)
</code></pre>

<p>Is there a better way to do this?</p>

<p>Looks like the data would be better viewed on a logarithmic scale. On your matplotlib plot axis, <code>ax</code>, use:</p>

<pre><code>ax.set_yscale('log')
</code></pre>

python matplotlib histogram seaborn