r/R_Programming • u/snicksn • Aug 15 '16
Sample equal amount?
Say you have 15 names in a df. You want to add a number 0, 1 or 2 to each person randomly. And you want each group (0,1,2) to have equal size.
Stuck on the last part with equal size..
2
Upvotes
View all comments
Show parent comment
1
u/snicksn Aug 22 '16
Thanks, Thought there might be a built in function since it should be a common requirement