-4

I have a column of continuous values. Say 1 to 10000. I want to make it to "n" buckets in considerable range, say from 1 to 1000 - call it as bucket 1, 1000 to 5000 bucket 2 etc. Is there any package available in R to do this

Thank you

Arun
  • 625
  • 3
  • 10
  • 20
  • @cathG - My apologizes for posting a duplicate question. Probably i didnt used correct words to search this question. sorry. – Arun Dec 15 '15 at 13:21

1 Answers1

3

We can try rep. In general, it is better to use cut or findInterval, but in this special case, rep also should work.

 rep(1:3, c(1000, 4000, 5000))
akrun
  • 874,273
  • 37
  • 540
  • 662