[R] place x-axis labels at bin edges in a histogram
ruipbarradas at sapo.pt
Thu Apr 4 13:10:49 CEST 2013
Try the following.
h <- hist(rnorm(100), xaxt = "n")
axis(1, at = h$breaks)
Hope this helps,
Em 04-04-2013 11:44, Shane Carey escreveu:
> I would like to places x-axis labels at the edge of bins on a histogram,
> i.e. the min value at first bin edge (left hand side) and max at the last
> bin edge (right hand side).
> As it stands, it places the values in the centre of each bin.
More information about the R-help