Give my data
ID Income
<dbl> <dbl>
1 0
2 2000
3 5000
4 2500
5 5000
6 2000
7 1000
8 16000
9 0
10 1000
...
There are about 100 rows this is a small sample. I tried to generate a table of frequency count to plot a histogram. In light of previous questions on this website, my codes are
options(scipen = 999)
Htable <- table(cut(df$Income, breaks=c(0,1,500,1000,2000,3000,5000,Inf),include.lowest=T))
But it returns
[0,1] (1,500] (500,1e+03] (1e+03,2e+03] (2e+03,3e+03]
11 6 29 42 12
(3e+03,5e+03] (5e+03,Inf]
6 1
Do you know why this happens and how can I change it to standard expression?
Thank you very much!