So basically I randomly ~ 200 unique IDs "numbers" (strings that contain a letter and a number eg x1,
X2, y40, ...) and some id "numbers" are not assigned to any group in the group of 5 groups without any replication.
For the least work example, I have 32 unique ID "numbers" on which I use 11 unique ID "numbers" with "21 unique ID" numbers "using" 7 of 3 I want to sort in groups. # 32 Unique ID id = C ("y6", "x1", "x3", "x4", "x5", "x12", "x7", "x8",
"X9", "z6", "x10", "y1", "x11", "z3", "y2", "y3", "y4", "y5", "y7", "y8", "y9 "," Z10 "," z10 "," z1 "," z1 "," z1 "," z1 "," z8 "," z1 "," 2 "," z2 "," z4 "," z5 "," z7 " "X2") # and how will I create the first group of 3 unique ID "numbers" sample (id, 3, location = FALSE, replace prob = NULL) #Output [1] "x3" "x6" "y8 "So far, one way to do this is to select the next group from ID and group 3 without removing the selected number of thAs long as I have 7 groups of 3? Since it is possible for small datasets, but not for the big ones.
PS: Yes I have searched, but whatever has been implemented I did not get it and I'm a little bit of R. NuB.
I think it should work, Actually randomize random vectors to a group, you can divide it into a list, but Uje think it is better to keep the data. Frame
`ID & lt; - Sample (ID, Length (ID), Replaced = FALSE) ID & lt; - data.frame (id) id $ group & lt; - Rooftop (seq_along (id $ id) / 3) `` `