Label the x axis correct in a histogram in R
<p>I tried to name the x axis correct.</p>

<pre><code>hist(InsectSprays$count, col='pink', xlab='Sprays', labels=levels(InsectSprays$spray), xaxt='n')
axis(1, at=unique(InsectSprays$spray), labels=levels(InsectSprays$spray))
</code></pre>

<p>But this produces</p>

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

<p>I want the letters below the bars and not on top.</p>