
Dear R-listers,
I am using R 3.1, I amtrying to generate 40 patients in each treatment group with 12 block,  Equal number of treatment in each block ,using stratification Variable age65(yes, no),surgery(yes ,no) and smoke (yes, no)
 
How can i creat like thislist in R.
 
  
  
block identifier
  
  
  
 block size
  
  
  
 sequence  within block
  
  
  
 treatment
  
  
  
 age65
  
  
  
 surgery
  
  
  
 smoke
  
 
 
  
  
1
  
  
  
12
  
  
  
1
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
2
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
3
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
4
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
5
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
6
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
7
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
8
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
9
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
10
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
11
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
1
  
  
  
12
  
  
  
12
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
Yes
  
 
 
  
  
2
  
  
  
12
  
  
  
1
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
2
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
3
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
4
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
5
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
6
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
7
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
8
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
9
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
10
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
11
  
  
  
Group A
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 
 
  
  
2
  
  
  
12
  
  
  
12
  
  
  
Group B
  
  
  
yes
  
  
  
yes
  
  
  
no
  
 

 
I am very appreciate yourtime to answer my question
 
Thanks
Sug

	[[alternative HTML version deleted]]

