[R] randomizing groups

Jason Priem priem at email.unc.edu
Fri Oct 2 22:36:36 CEST 2009


I have a list of participants in a study, identified by number.  I want 
to randomly sort them into an arbitrary number of groups. 
split(sample(1:96, 96), 1:16)
almost does it, but it only works where the division is even.  Any ideas?
Thanks!

Jason Priem,
Doctoral Student,
School of Information and Library Science
University of North Carolina-Chapel Hill




More information about the R-help mailing list