I am using SAS 9.3.
I am interested in generating a dataset containing all possible permutations of 3 drugs in a block size of 6, with equal numbers of each trial (1:1:1). That is, if the treatments are A, B, C and I have a block size of 6 with 2 As, 2 Bs and 2 Cs, then some possible blocks include the following:
AABBCC
AACCBB
ABACCB
AABCCB
etc.
The important thing is that I must have each treatment repeating twice and only twice per block. Because each treatment must be present twice in each block--this is usually where I have been running into problems with other code that i have tried. I have unsucessfuly tried to generate this in IML and PROC PLAN (using the TREATMENTS statement).
I have tried to implement a process in IML, which is great, but it provides duplicates when I only want to see the unique permutations. Here is that code:
proc iml;
call randseed(1234);
tName = "Treat1":"Treat6";
perms = allperm({A A B B C C});
Any help would be appreciated!
... View more