obsessive - compulsive disorder ( ocd ) , for instance , has only been studied in small trials . first - line treatments such as clomipramine and selective serotonin reuptake inhibitors are typically studied in trials with no more than two hundred patients.1 for second - line treatments such as pharmacological augmentation strategies , the situation is worse , albeit understandably so.2,3 to our knowledge , no trials have investigated these strategies using more than one hundred patients . indeed , most such studies have presented final sample sizes of no more than 15 patients per arm.3 this is in stark contrast to studies of common clinical diseases such as hypertension and diabetes . therefore , certain specific aspects of trial design need to be taken into consideration when implementing clinical trials involving psychiatric patients , especially those with ocd . in small trials , such as those typically used to study psychiatric disorders , an imbalance in prognostic factors between treatment arms can affect the interpretation of the results . one of the first methods created to address this problem was stratified allocation of individuals.4 the use of this method also reduces the need to adjust statistical data analyses for covariates that serve as prognostic factors . the limitation of stratified allocation is that it can only be applied when a small number of covariates are involved . otherwise , the sample has to be divided into a large number of strata with only a very few patients in each.5 in order to overcome this limitation , it is necessary to devise alternative methods of minimizing imbalance among treatment arms . pocock and simon6 devised a general procedure for treatment assignment that minimizes imbalance among individual prognostic factors . independently , taves7 also developed a minimization procedure that will not be discussed in this article , as it is encompassed by the pocock and simon method . since 1975 , various other authors have developed procedures to minimize the risk of imbalance between arms , as reviewed elsewhere.8,9 each method has specific limitations and complexities . for example , the optimal allocation technique allows the use of continuous variables in their non - categorical format as covariates.10 however , the complexity and associated difficulty has limited its practical implementation . no allocation procedure is ideal - accordingly , novel methods are still required in specific situations . in response to the need for specific minimization procedures in clinical trials involving individuals with ocd , we developed an allocation method that uses the aitchison distance,1113 which is a measure for compositional data ( data that contains quantitative descriptions of the parts of some whole ) . the aitchison distance was chosen because all prognostic factors used are better classified as categorical data with relative frequencies that can be taken as compositional data in nature . we present allocation results for a partial sample collected during the first year of the study for which this procedure was developed , as well as results for simulated samples that feature variable patient s order of inclusion . the trials reported in this manuscript received prior approval from our local ethics committee . for clarity , let us first consider the simplest design . consider a clinical trial in which patients are enrolled sequentially , according to the order in which they commence treatment at the clinic . each patient is to be assigned to one , and only one , of two alternative treatments . imagine that a new patient arrives after the study already included a considerable number of patients in each of the two arms : n1 and n2 . in addition , consider that age , denoted a , is a factor for which we think adjustment should be made . possible ages are divided into three different categories : a1 if a  30 ; a2 if 30 < a  45 ; and a3 if a > 45 . consider now the following notation : 
 represent the sample absolute frequencies of n1 and n2 , respectively , as ( n11,n12,n13 ) and ( n21,n22,n23 ) , i.e. , for i = 1 or 2 and j = 1 , 2 or 3 , nij is the number of patients of age group aj in arm i.represent the compositional vectors ( relative frequency vectors ) , respectively , as a1 = ( a11,a12,a13 ) and a2 = ( a21,a22,a23 ) . thus , aij = nij / ni represents the relative frequency of patients in age group aj in arm i given the proportion of age group aj in arm i. represent the sample absolute frequencies of n1 and n2 , respectively , as ( n11,n12,n13 ) and ( n21,n22,n23 ) , i.e. , for i = 1 or 2 and j = 1 , 2 or 3 , nij is the number of patients of age group aj in arm i. represent the compositional vectors ( relative frequency vectors ) , respectively , as a1 = ( a11,a12,a13 ) and a2 = ( a21,a22,a23 ) . thus , aij = nij / ni represents the relative frequency of patients in age group aj in arm i given the proportion of age group aj in arm i. the allocation of a new incoming patient consists of the following steps : 
 consider including the new patient in the first arm , in which case we represent the new composition vector by ( a1 ) * , and we calculate the distance between ( a1 ) * and a2 by evaluating d1 =  [ ( a1)*;a2].consider including the new patient in the second arm , in which case we represent the new compositional vector by ( a2 ) * , and compute the distance d2=  [ a1;(a2)*].compare the values of d1 and d2 . if d1 < d2 , we allocate the new patient to n1 ; if d1 > d2 , we allocate the patient to n2 ; and if d1 = d2 , the patient may be allocated to either arm ( at random ) . consider including the new patient in the first arm , in which case we represent the new composition vector by ( a1 ) * , and we calculate the distance between ( a1 ) * and a2 by evaluating d1 =  [ ( a1)*;a2 ] . consider including the new patient in the second arm , in which case we represent the new compositional vector by ( a2 ) * , and compute the distance d2=  [ a1;(a2 ) * ] . < d2 , we allocate the new patient to n1 ; if d1 > d2 , we allocate the patient to n2 ; and if d1 = d2 , the patient may be allocated to either arm ( at random ) . note that we make our decision based on the values of the distances between the compositional vectors . we use the term  compositional vectors  to designate vectors for which the sum of their components is fixed and known . in our case , with relative frequencies , the values of the components are numbers in the interval [ 0;1 ] , and the sum of these components is one . aitchison11,12 argued that , for compositional data , the correct distance measure is not the usual standard euclidian measure but is instead as described below . in general , consider factor a having k ( > 1 ) possible alternatives , i.e. , ai = ( ai1,ai2,  ,aik ) is the relative frequency vector of arm i ( = 1,2 ) . for category j , consider the natural logarithm of the between - arm relative frequency ratio , rj = ( a1j  a2j ) , denoted by ln(rj ) , and the mean of these logarithms , denoted by l : 
 ln(rj)=ln(a1j)ln(a2j )  and  l={ln(r1)+ln(r2)+ ... +ln(rk)}k the aitchison distance measure between the two compositional vectors a1 and a2 is defined as follows : 
 [a1,a2]=j=1k{ln(rj)l}2 to demonstrate the allocation procedure , let us consider the case of the three age categories a1 , a2 , and a3 , as before . suppose that , in one stage of the process , we encountered the following vectors of absolute frequencies : n1 = ( 3;7;5 ) and n2 = ( 5;6;6 ) . the following three expressions represent the intragroup distances , ( not ) including the new patient : 
 before the arrival of the new patient , [a1;a2 ] = 0.4702with the new patient in n1 , [(a1)*;a2 ] = 0.5676with the new patient in n2 ,  [ a1;(a2 ) * ] = 0.3661 before the arrival of the new patient , [a1;a2 ] = 0.4702 with the new patient in n1 , [(a1)*;a2 ] = 0.5676 with the new patient in n2 ,  [ a1;(a2 ) * ] = 0.3661 the figures above indicate that a new patient in age group a2 should best be allocated to n2 . this conclusion might appear obvious to the decision - maker , as it is desirable to increase the frequency of a2 in n2 . let us consider the vectors s1 = ( s1;s2 )  s and s2 = ( s2;s1 )  s as the relative frequencies of n1 and n2 , respectively . in our example we would have the following : 
 s1=(15;17)32=(.47;.53 ) ,  s2=(.53;.47 )  ,  ( s1 ) *  = ( .48;.52 )  and  ( s2)*=(.55;.45 ) here the * indicates that the new patient entered a specific arm . the new distance values are  [ s1;s2 ] = 0.1770 , [(s1)*;s2 ] = 0.1314 , and  [ s1;(s2 ) * ] = 0.2174 . clearly , the best allocation would be to the first arm , which features a smaller sample size . bear in mind that , given the age categories above , our best choice would have been to allocate the new patient to the second arm . however , considering the sample size factor , the first arm is the more appropriate allocation for the new patient . if the decision - maker feels that age is more important than sample size , a larger weight could be assigned to age than to sample size . for example , consider our decision to use a weight of 2 for age and a weight of 1 for sample size . the weights reflect the importance of covariates and should be prospectively made in agreement with the investigators . the results for our example are as follows : 
 new patient in n1 produces d1 = { 2[(a1)*;a2 ] + [(s1)*;s2 ] }  3 = 0.4222new patient in n2 produces d2 = { 2[a1;(a2 ) * ] + [s1;(s2 ) * ] }  3 = 0.3165 new patient in n1 produces d1 = { 2[(a1)*;a2 ] + [(s1)*;s2 ] }  3 = 0.4222 new patient in n2 produces d2 = { 2[a1;(a2 ) * ] + [s1;(s2 ) * ] }  3 = 0.3165 the overall distance using the two factors indicates that the new patient should be allocated to n2 in order to bring the arms closer in terms of age and sample size . it may also be possible to assign equal weights to the two factors . regarding the constructed factor for sample size , to appropriately compare factors , we need to adopt the same range for all factor distance measures . the examples discussed below are more specific and demonstrate several interesting particularities . the first , related to phase one of the trial described , deals with two arms , four prognostic factors , and a simultaneous allocation of three patients each time . the second example , related to phase two , deals with seven prognostic factors and allocation of patients one at a time into the three groups . a study group specializing in ocd wished to conduct a clinical trial consisting of two phases . the objective of phase one was to compare patient responses to pharmacological and psychotherapeutic treatments . they expected that 360 ocd patients would be enrolled in phase one over a 3-year period . however , for logistical reasons , they did not anticipate that the numbers of patients allocated to the individual treatment arms would be similar in phase one . they anticipated that the pharmacological arm may receive more patients than the psychotherapeutic arm at certain times , and vice - versa at other times . these variations are required because , for practical reasons , each therapeutic arm must accommodate a different number of patients at different times in the study . as the psychotherapeutic arm involves group psychotherapy , when groups are first created , a rapid influx of patients is necessary , but when groups are well - established , the speed of inclusion should diminish as only two groups can be conducted simultaneously . from previous experience , we expected that 60% of the patients treated in either of the two arms of phase one would report less than adequate symptom improvement . patients who participated in the pharmacological arm ( n1 ) and did not respond to treatment would be invited to participate in phase two . patients who were non - responders in the psychotherapeutic arm ( n2 ) of phase one would be invited to participate in the pharmacological arm ( n1 ) , and , if treatment resistance were to persist in n1 , they would also be invited to participate in phase two . phase two consists of three arms , the objective being to compare three different pharmacological augmentation strategies . in phase two , unlike in phase one , it is expected that a similar number of patients will be allocated to each of the three arms . considering expected response rates , drop - out rates , and frequency of refusals to participate in a study using a placebo , it is likely that 30 to 40 patients will be included in each arm . the allocation strategies for the two phases of the trial are different . to accommodate the logistical characteristics of phase one ( that require a different pace of patient enrollment for each arm at different study time points ) , the researcher will receive groups of 3 patients to be allocated into the two groups . on some occasions , it might be necessary to allocate 2 patients to n1 and 1 to n2 . on other , well - defined occasions , the situation is reversed , and n1 will receive 1 patient while the other 2 patients will be allocated to n2 . when the allocation program was developed for phase one , a smaller number of variables was chosen , as we did not know how many covariates this new procedure could accommodate without compromising its efficiency in minimizing arm imbalance . after the initial results of allocation were analyzed for phase one , it became clear that the procedure could accommodate a greater number of covariates . therefore , the program for phase two was designed with a greater number of hypothesized prognostic factors that could also have been covariates in phase one . although the appropriateness of the factors used might be obvious , discussion of these choices is outside the scope of this paper . the factors and their categories were as follows : 
 current age ( age ) was categorized into three classes : under 30 years of age ( a0 ) ; between 31 and 45 ( a1 ) ; and over 45 ( a2).ocd symptom severity ( ocd ) , as measured using the yale - brown obsessive - compulsive scale ( y - bocs ) , was categorized under one of eight classes based on ordered scores for each of the two symptom types ( obsession and compulsion ) :  8 = low ( l ) ; 815 = moderate ( m ) ; and > 15 = high ( h ) . therefore , the eight possible classes were as follows : ( l;l ) , ( l;m ) , ( l;h ) , ( m;l ) , ( m;m ) , ( m;h ) , ( h;l ) , ( h;m ) , and ( h;h ) . the first and second notations are based on the scores for obsession and compulsion , respectively . clearly , ( l;l ) is not considered , as it would indicate no ocd symptoms , and we had no patients in this class.treatment history ( his ) was divided into three categories in each phase . in phase one , h0 indicates no previous appropriate treatment , h1 indicates one previous course of appropriate treatment without response , and h2 indicates two or more previous courses of appropriate treatment without response . in phase two , h0 indicates no y - bocs score reduction or y - bocs score increase after n1 in phase one , h1 indicates a 120% reduction in y - bocs score after n1 in phase one , and h2 indicates a 2035% reduction in y - bocs score after n1 in phase one.level of education ( sch ) was divided into four categories : sc0 indicates no schooling , sc1 indicates  8 years of schooling , sc2 indicates 912 years of schooling , and sc3 indicates higher education ( undergraduate or graduate work).marital status ( mar ) was categorized as si0 ( married , divorced or widowed ) or si1 ( single , never married).genders ( gen ) are indicated by m for male and f for female.sample sizes ( sam ) are denoted as s1 , s2 , s3 , and s = s1 + s2 + s3 represents the total sample size . the compositional vector of sample size in arm i ( i = 1,2,3 ) is the vector ( pi;1pi ) where pi = si  s. current age ( age ) was categorized into three classes : under 30 years of age ( a0 ) ; between 31 and 45 ( a1 ) ; and over 45 ( a2 ) . ocd symptom severity ( ocd ) , as measured using the yale - brown obsessive - compulsive scale ( y - bocs ) , was categorized under one of eight classes based on ordered scores for each of the two symptom types ( obsession and compulsion ) :  8 = low ( l ) ; 815 = moderate ( m ) ; and > 15 = high ( h ) . therefore , the eight possible classes were as follows : ( l;l ) , ( l;m ) , ( l;h ) , ( m;l ) , ( m;m ) , ( m;h ) , ( h;l ) , ( h;m ) , and ( h;h ) . the first and second notations are based on the scores for obsession and compulsion , respectively . clearly , ( l;l ) is not considered , as it would indicate no ocd symptoms , and we had no patients in this class . treatment history ( his ) was divided into three categories in each phase . in phase one , h0 indicates no previous appropriate treatment , h1 indicates one previous course of appropriate treatment without response , and h2 indicates two or more previous courses of appropriate treatment without response . in phase two , h0 indicates no y - bocs score reduction or y - bocs score increase after n1 in phase one , h1 indicates a 120% reduction in y - bocs score after n1 in phase one , and h2 indicates a 2035% reduction in y - bocs score after n1 in phase one . level of education ( sch ) was divided into four categories : sc0 indicates no schooling , sc1 indicates  8 years of schooling , sc2 indicates 912 years of schooling , and sc3 indicates higher education ( undergraduate or graduate work ) . marital status ( mar ) was categorized as si0 ( married , divorced or widowed ) or si1 ( single , never married ) . sample sizes ( sam ) are denoted as s1 , s2 , s3 , and s = s1 + s2 + s3 represents the total sample size . the compositional vector of sample size in arm i ( i = 1,2,3 ) is the vector ( pi;1pi ) where pi = si  s. for each of these factors , the distance between arms can be computed . the distance values for the seven variables listed above are given by the following symbols : age , ocd , his , sch , mar , gen , and sam . the global distances for phases one and two are , respectively , 1 and 2 , defined as follows : 
 1=(2age+3ocd+3his+gen)92=(2age+4ocd+5his+2sch+3mar+gen+4sam)21 as there are three arms in phase two , there are also three vectors . hence the global distance for phase two should be the average of the three values of 2 , i.e. , the distance for phase two should be as follows : 
 2={2(n1;n2)+2(n1;n3)+2(n2;n3)}3 based on previous studies , factors measurable before treatment initiation may influence the treatment response . therefore , it is desirable that certain prognostic factors be distributed as homogeneously as possible between the two arms . we assume that previous treatment response ( assessed through patient interviews ) and severity of the disorder ( assessed using a specific scale ) at the time of inclusion in the study are the most important prognostic factors for clinical response . in addition , although of lesser importance to treatment response , gender and age should also be homogeneously distributed between arms . for logistical reasons , it was not possible to enroll the same number of patients in each phase one treatment arm . the healthcare professionals who administer the treatments can assist more patients in the pharmacological arm than in the psychotherapeutic arm . over the course of the study , there are times at which the pace of patient enrollment into the psychotherapeutic arm is , of necessity , more rapid than that of patient enrollment into the pharmacological arm . we expect that the pharmacological arm will account for a higher percentage of the final sample . due to the time needed to perform the clinical evaluations , there is a two - week gap between inclusion and allocation . consequently , it is possible to allocate patients simultaneously in groups of three , one to one arm and the remaining two to the other arm ( the arm that receives two patients at certain time points will only receive one at other time points ) . this simultaneous inclusion of patients guarantees that provider blinding is not compromised by allocation in small blocks . the choice of prognostic factors to be balanced between arms is based on reports in the literature that suggest that these prognostic factors may influence the results considerably . in addition , having information about these factors at the time of the initial evaluation is feasible and provides useful clues for balancing between intervention groups . as previous treatment response and initial severity are known to be associated with treatment response in clinical trials evaluating ocd patients,1418 they were included as prognostic factors in order to balance the arms . patients entering phase two were those that failed to completely respond to the treatment in n1 of phase one ( regardless of treatment history ) . the investigators assumed that treatment response and current severity were highly predictive of phase two treatment response , and that these patients should therefore be distributed homogeneously among the three groups . in addition , it is understood from previous studies that level of education and marital status are significantly associated with poor treatment response and should be included in the phase two strategy model . another important factor is sample size , which should be as similar as possible among the three arms . for each patient in phase two , the allocation to one of the three arms needs to be determined during the evaluation conducted at week 12 of treatment . the strategy at this point involves a sequential , one - by - one allocation of patients who had participated in phase one . here , in addition to having more than two factors to consider in our attempts to balance the arms bear in mind that though the distance measures are defined for two vectors in order to facilitate decisions regarding patient allocation , we consider the average of the three distances between pairs to represent the overall distance of the three arms . for clarity , let us first consider the simplest design . consider a clinical trial in which patients are enrolled sequentially , each patient is to be assigned to one , and only one , of two alternative treatments . imagine that a new patient arrives after the study already included a considerable number of patients in each of the two arms : n1 and n2 . in addition , consider that age , denoted a , is a factor for which we think adjustment should be made . possible ages are divided into three different categories : a1 if a  30 ; a2 if 30 < a  45 ; and a3 if a > 45 . consider now the following notation : 
 represent the sample absolute frequencies of n1 and n2 , respectively , as ( n11,n12,n13 ) and ( n21,n22,n23 ) , i.e. , for i = 1 or 2 and j = 1 , 2 or 3 , nij is the number of patients of age group aj in arm i.represent the compositional vectors ( relative frequency vectors ) , respectively , as a1 = ( a11,a12,a13 ) and a2 = ( a21,a22,a23 ) . thus , aij = nij / ni represents the relative frequency of patients in age group aj in arm i given the proportion of age group aj in arm i. represent the sample absolute frequencies of n1 and n2 , respectively , as ( n11,n12,n13 ) and ( n21,n22,n23 ) , i.e. , for i = 1 or 2 and j = 1 , 2 or 3 , nij is the number of patients of age group aj in arm i. represent the compositional vectors ( relative frequency vectors ) , respectively , as a1 = ( a11,a12,a13 ) and a2 = ( a21,a22,a23 ) . thus , aij = nij / ni represents the relative frequency of patients in age group aj in arm i given the proportion of age group aj in arm i. the allocation of a new incoming patient consists of the following steps : 
 consider including the new patient in the first arm , in which case we represent the new composition vector by ( a1 ) * , and we calculate the distance between ( a1 ) * and a2 by evaluating d1 =  [ ( a1)*;a2].consider including the new patient in the second arm , in which case we represent the new compositional vector by ( a2 ) * , and compute the distance d2=  [ a1;(a2)*].compare the values of d1 and d2 . if d1 < d2 , we allocate the new patient to n1 ; if d1 > d2 , we allocate the patient to n2 ; and if d1 = d2 , the patient may be allocated to either arm ( at random ) . consider including the new patient in the first arm , in which case we represent the new composition vector by ( a1 ) * , and we calculate the distance between ( a1 ) * and a2 by evaluating d1 =  [ ( a1)*;a2 ] . consider including the new patient in the second arm , in which case we represent the new compositional vector by ( a2 ) * , and compute the distance d2=  [ a1;(a2 ) * ] . < d2 , we allocate the new patient to n1 ; if d1 > d2 , we allocate the patient to n2 ; and if d1 = d2 , the patient may be allocated to either arm ( at random ) . note that we make our decision based on the values of the distances between the compositional vectors . we use the term  compositional vectors  to designate vectors for which the sum of their components is fixed and known . in our case , with relative frequencies , the values of the components are numbers in the interval [ 0;1 ] , and the sum of these components is one . aitchison11,12 argued that , for compositional data , the correct distance measure is not the usual standard euclidian measure but is instead as described below . in general , consider factor a having k ( > 1 ) possible alternatives , i.e. , ai = ( ai1,ai2,  ,aik ) is the relative frequency vector of arm i ( = 1,2 ) . for category j , consider the natural logarithm of the between - arm relative frequency ratio , rj = ( a1j  a2j ) , denoted by ln(rj ) , and the mean of these logarithms , denoted by l : 
 ln(rj)=ln(a1j)ln(a2j )  and  l={ln(r1)+ln(r2)+ ... +ln(rk)}k the aitchison distance measure between the two compositional vectors a1 and a2 is defined as follows : 
 [a1,a2]=j=1k{ln(rj)l}2 to demonstrate the allocation procedure , let us consider the case of the three age categories a1 , a2 , and a3 , as before . suppose that , in one stage of the process , we encountered the following vectors of absolute frequencies : n1 = ( 3;7;5 ) and n2 = ( 5;6;6 ) . the following three expressions represent the intragroup distances , ( not ) including the new patient : 
 before the arrival of the new patient , [a1;a2 ] = 0.4702with the new patient in n1 , [(a1)*;a2 ] = 0.5676with the new patient in n2 ,  [ a1;(a2 ) * ] = 0.3661 before the arrival of the new patient , [a1;a2 ] = 0.4702 with the new patient in n1 , [(a1)*;a2 ] = 0.5676 with the new patient in n2 ,  [ a1;(a2 ) * ] = 0.3661 the figures above indicate that a new patient in age group a2 should best be allocated to n2 . this conclusion might appear obvious to the decision - maker , as it is desirable to increase the frequency of a2 in n2 . let us consider the vectors s1 = ( s1;s2 )  s and s2 = ( s2;s1 )  s as the relative frequencies of n1 and n2 , respectively . in our example we would have the following : 
 s1=(15;17)32=(.47;.53 ) ,  s2=(.53;.47 )  ,  ( s1 ) * = ( .48;.52 )  and  ( s2)*=(.55;.45 ) here the * indicates that the new patient entered a specific arm . the new distance values are  [ s1;s2 ] = 0.1770 , [(s1)*;s2 ] = 0.1314 , and  [ s1;(s2 ) * ] = 0.2174 . clearly , the best allocation would be to the first arm , which features a smaller sample size . bear in mind that , given the age categories above , our best choice would have been to allocate the new patient to the second arm . however , considering the sample size factor , the first arm is the more appropriate allocation for the new patient . if the decision - maker feels that age is more important than sample size , a larger weight could be assigned to age than to sample size . for example , consider our decision to use a weight of 2 for age and a weight of 1 for sample size . the weights reflect the importance of covariates and should be prospectively made in agreement with the investigators . the results for our example are as follows : 
 new patient in n1 produces d1 = { 2[(a1)*;a2 ] + [(s1)*;s2 ] }  3 = 0.4222new patient in n2 produces d2 = { 2[a1;(a2 ) * ] + [s1;(s2 ) * ] }  3 = 0.3165 new patient in n1 produces d1 = { 2[(a1)*;a2 ] + [(s1)*;s2 ] }  3 = 0.4222 new patient in n2 produces d2 = { 2[a1;(a2 ) * ] + [s1;(s2 ) * ] }  3 = 0.3165 the overall distance using the two factors indicates that the new patient should be allocated to n2 in order to bring the arms closer in terms of age and sample size . it may also be possible to assign equal weights to the two factors . regarding the constructed factor for sample size , to appropriately compare factors , we need to adopt the same range for all factor distance measures . the first , related to phase one of the trial described , deals with two arms , four prognostic factors , and a simultaneous allocation of three patients each time . the second example , related to phase two , deals with seven prognostic factors and allocation of patients one at a time into the three groups . a study group specializing in ocd wished to conduct a clinical trial consisting of two phases . the objective of phase one was to compare patient responses to pharmacological and psychotherapeutic treatments . they expected that 360 ocd patients would be enrolled in phase one over a 3-year period . however , for logistical reasons , they did not anticipate that the numbers of patients allocated to the individual treatment arms would be similar in phase one . they anticipated that the pharmacological arm may receive more patients than the psychotherapeutic arm at certain times , and vice - versa at other times . these variations are required because , for practical reasons , each therapeutic arm must accommodate a different number of patients at different times in the study . as the psychotherapeutic arm involves group psychotherapy , when groups are first created , a rapid influx of patients is necessary , but when groups are well - established , the speed of inclusion should diminish as only two groups can be conducted simultaneously . from previous experience , we expected that 60% of the patients treated in either of the two arms of phase one would report less than adequate symptom improvement . patients who participated in the pharmacological arm ( n1 ) and did not respond to treatment would be invited to participate in phase two . patients who were non - responders in the psychotherapeutic arm ( n2 ) of phase one would be invited to participate in the pharmacological arm ( n1 ) , and , if treatment resistance were to persist in n1 , they would also be invited to participate in phase two . phase two consists of three arms , the objective being to compare three different pharmacological augmentation strategies . in phase two , unlike in phase one , it is expected that a similar number of patients will be allocated to each of the three arms . considering expected response rates , drop - out rates , and frequency of refusals to participate in a study using a placebo , it is likely that 30 to 40 patients will be included in each arm . the allocation strategies for the two phases of the trial are different . to accommodate the logistical characteristics of phase one ( that require a different pace of patient enrollment for each arm at different study time points ) , the researcher will receive groups of 3 patients to be allocated into the two groups . on some occasions , it might be necessary to allocate 2 patients to n1 and 1 to n2 . on other , well - defined occasions , the situation is reversed , and n1 will receive 1 patient while the other 2 patients will be allocated to n2 . when the allocation program was developed for phase one , a smaller number of variables was chosen , as we did not know how many covariates this new procedure could accommodate without compromising its efficiency in minimizing arm imbalance . after the initial results of allocation were analyzed for phase one , it became clear that the procedure could accommodate a greater number of covariates . therefore , the program for phase two was designed with a greater number of hypothesized prognostic factors that could also have been covariates in phase one . although the appropriateness of the factors used might be obvious , discussion of these choices is outside the scope of this paper . the factors and their categories were as follows : 
 current age ( age ) was categorized into three classes : under 30 years of age ( a0 ) ; between 31 and 45 ( a1 ) ; and over 45 ( a2).ocd symptom severity ( ocd ) , as measured using the yale - brown obsessive - compulsive scale ( y - bocs ) , was categorized under one of eight classes based on ordered scores for each of the two symptom types ( obsession and compulsion ) :  8 = low ( l ) ; 815 = moderate ( m ) ; and > 15 = high ( h ) . therefore , the eight possible classes were as follows : ( l;l ) , ( l;m ) , ( l;h ) , ( m;l ) , ( m;m ) , ( m;h ) , ( h;l ) , ( h;m ) , and ( h;h ) . the first and second notations are based on the scores for obsession and compulsion , respectively . clearly , ( l;l ) is not considered , as it would indicate no ocd symptoms , and we had no patients in this class.treatment history ( his ) was divided into three categories in each phase . in phase one , h0 indicates no previous appropriate treatment , h1 indicates one previous course of appropriate treatment without response , and h2 indicates two or more previous courses of appropriate treatment without response . in phase two , h0 indicates no y - bocs score reduction or y - bocs score increase after n1 in phase one , h1 indicates a 120% reduction in y - bocs score after n1 in phase one , and h2 indicates a 2035% reduction in y - bocs score after n1 in phase one.level of education ( sch ) was divided into four categories : sc0 indicates no schooling , sc1 indicates  8 years of schooling , sc2 indicates 912 years of schooling , and sc3 indicates higher education ( undergraduate or graduate work).marital status ( mar ) was categorized as si0 ( married , divorced or widowed ) or si1 ( single , never married).genders ( gen ) are indicated by m for male and f for female.sample sizes ( sam ) are denoted as s1 , s2 , s3 , and s = s1 + s2 + s3 represents the total sample size . the compositional vector of sample size in arm i ( i = 1,2,3 ) is the vector ( pi;1pi ) where pi = si  s. current age ( age ) was categorized into three classes : under 30 years of age ( a0 ) ; between 31 and 45 ( a1 ) ; and over 45 ( a2 ) . ocd symptom severity ( ocd ) , as measured using the yale - brown obsessive - compulsive scale ( y - bocs ) , was categorized under one of eight classes based on ordered scores for each of the two symptom types ( obsession and compulsion ) :  8 = low ( l ) ; 815 = moderate ( m ) ; and > 15 = high ( h ) . therefore , the eight possible classes were as follows : ( l;l ) , ( l;m ) , ( l;h ) , ( m;l ) , ( m;m ) , ( m;h ) , ( h;l ) , ( h;m ) , and ( h;h ) . the first and second notations are based on the scores for obsession and compulsion , respectively . clearly , ( l;l ) is not considered , as it would indicate no ocd symptoms , and we had no patients in this class . treatment history ( his ) was divided into three categories in each phase . in phase one , h0 indicates no previous appropriate treatment , h1 indicates one previous course of appropriate treatment without response , and h2 indicates two or more previous courses of appropriate treatment without response . in phase two , h0 indicates no y - bocs score reduction or y - bocs score increase after n1 in phase one , h1 indicates a 120% reduction in y - bocs score after n1 in phase one , and h2 indicates a 2035% reduction in y - bocs score after n1 in phase one . level of education ( sch ) was divided into four categories : sc0 indicates no schooling , sc1 indicates  8 years of schooling , sc2 indicates 912 years of schooling , and sc3 indicates higher education ( undergraduate or graduate work ) . marital status ( mar ) was categorized as si0 ( married , divorced or widowed ) or si1 ( single , never married ) . genders ( gen ) are indicated by m for male and f for female . sample sizes ( sam ) are denoted as s1 , s2 , s3 , and s = s1 + s2 + s3 represents the total sample size . the compositional vector of sample size in arm i ( i = 1,2,3 ) is the vector ( pi;1pi ) where pi = si  s. for each of these factors , the distance between arms can be computed . the distance values for the seven variables listed above are given by the following symbols : age , ocd , his , sch , mar , gen , and sam . the global distances for phases one and two are , respectively , 1 and 2 , defined as follows : 
 1=(2age+3ocd+3his+gen)92=(2age+4ocd+5his+2sch+3mar+gen+4sam)21 as there are three arms in phase two , there are also three vectors . hence the global distance for phase two should be the average of the three values of 2 , i.e. , the distance for phase two should be as follows : 
 2={2(n1;n2)+2(n1;n3)+2(n2;n3)}3 based on previous studies , factors measurable before treatment initiation may influence the treatment response . therefore , it is desirable that certain prognostic factors be distributed as homogeneously as possible between the two arms . we assume that previous treatment response ( assessed through patient interviews ) and severity of the disorder ( assessed using a specific scale ) at the time of inclusion in the study are the most important prognostic factors for clinical response . in addition , although of lesser importance to treatment response , gender and age should also be homogeneously distributed between arms . for logistical reasons , it was not possible to enroll the same number of patients in each phase one treatment arm . the healthcare professionals who administer the treatments can assist more patients in the pharmacological arm than in the psychotherapeutic arm . over the course of the study , there are times at which the pace of patient enrollment into the psychotherapeutic arm is , of necessity , more rapid than that of patient enrollment into the pharmacological arm . we expect that the pharmacological arm will account for a higher percentage of the final sample . due to the time needed to perform the clinical evaluations , there is a two - week gap between inclusion and allocation . consequently , it is possible to allocate patients simultaneously in groups of three , one to one arm and the remaining two to the other arm ( the arm that receives two patients at certain time points will only receive one at other time points ) . this simultaneous inclusion of patients guarantees that provider blinding is not compromised by allocation in small blocks . the choice of prognostic factors to be balanced between arms is based on reports in the literature that suggest that these prognostic factors may influence the results considerably . in addition , having information about these factors at the time of the initial evaluation is feasible and provides useful clues for balancing between intervention groups . as previous treatment response and initial severity are known to be associated with treatment response in clinical trials evaluating ocd patients,1418 they were included as prognostic factors in order to balance the arms . patients entering phase two were those that failed to completely respond to the treatment in n1 of phase one ( regardless of treatment history ) . the investigators assumed that treatment response and current severity were highly predictive of phase two treatment response , and that these patients should therefore be distributed homogeneously among the three groups . in addition , it is understood from previous studies that level of education and marital status are significantly associated with poor treatment response and should be included in the phase two strategy model . another important factor is sample size , which should be as similar as possible among the three arms . for each patient in phase two , the allocation to one of the three arms needs to be determined during the evaluation conducted at week 12 of treatment . the strategy at this point involves a sequential , one - by - one allocation of patients who had participated in phase one . here , in addition to having more than two factors to consider in our attempts to balance the arms , we are dealing with three arms . bear in mind that though the distance measures are defined for two vectors in order to facilitate decisions regarding patient allocation , we consider the average of the three distances between pairs to represent the overall distance of the three arms . this macro divided patients into homogenous intervention subgroups consistent with the factors chosen by investigators . to avoid empty categories in the allocation process , for a factor with k ( > 1 ) categories , we added to each category the fraction 1/k . therefore , no category had a frequency of 0 at the time of  distance calculation . the partition that provides the best degree of homogeneity between groups is defined as the division that minimized the difference between factor vectors of categorized relative frequencies . to calculate this measure , this distance was chosen based on the assumption that it preserves the sub - compositional coherence of the simplex space . after the values of 1 were calculated for each possible allocation , the allocation that resulted in the least intragroup distance was chosen as the optimal allocation . at the time of writing , 152 individuals had been allocated to n1 and 107 had been allocated to n2 . the phase two allocation system has the same objectives as that of phase one , namely to bring the arms as close together as possible in terms of the relevant prognostic factors . however , in phase two , the allocation logistics are different than those in phase one . we now have three arms , and the patients are allocated sequentially one - by - one . in addition , the balancing factors in this phase are different from those considered in phase one . as well as now accounting for level of education , marital status , and sample size , the previous treatment history factor , unlike in phase one , is based on the relative reduction , during phase one , in the y - bocs score . patients who present a > 35% reduction in y - bocs score are not included in this phase . in order to consider sample size as a factor , the proportion of patients in each group table 3 presents the allocation results for 90 patients selected from those in n1 of phase one . this macro divided patients into homogenous intervention subgroups consistent with the factors chosen by investigators . to avoid empty categories in the allocation process , for a factor with k ( > 1 ) categories , we added to each category the fraction 1/k . therefore , no category had a frequency of 0 at the time of  distance calculation . the partition that provides the best degree of homogeneity between groups is defined as the division that minimized the difference between factor vectors of categorized relative frequencies . to calculate this measure , this distance was chosen based on the assumption that it preserves the sub - compositional coherence of the simplex space . after the values of 1 were calculated for each possible allocation , the allocation that resulted in the least intragroup distance was chosen as the optimal allocation . at the time of writing , 152 individuals had been allocated to n1 and 107 had been allocated to n2 . the phase two allocation system has the same objectives as that of phase one , namely to bring the arms as close together as possible in terms of the relevant prognostic factors . however , in phase two , the allocation logistics are different than those in phase one . we now have three arms , and the patients are allocated sequentially one - by - one . in addition , the balancing factors in this phase are different from those considered in phase one . as well as now accounting for level of education , marital status , and sample size , the previous treatment history factor , unlike in phase one , is based on the relative reduction , during phase one , in the y - bocs score . patients who present a > 35% reduction in y - bocs score are not included in this phase . in order to consider sample size as a factor , the proportion of patients in each group table 3 presents the allocation results for 90 patients selected from those in n1 of phase one . the objective of using this strategy of random allocation of patients in different treatment arms is to avoid intentional bias in group allocation . however , treatment group imbalance for prognostic factors can still occur.9 these unfortunate consequences of randomization can only be prevented by using techniques that produce an intentional optimal allocation of patients to each treatment arm . another interesting point is the choice of the aitchison distance to treat compositional data . to illustrate the difference between the aitchison distance and the standard euclidian distance , we calculate the two distances for the pairs ( a1;a2 ) and ( b1;b2 ) of relative frequency vectors defined below : 
 a1=(0.1;0.2;0.7 ) ,  a2=(0.2;0.1;0.7 ) ,  b1=(0.2;0.4;0.4 ) ,  andb2=(0.4;0.2;0.4 ) the standard euclidian measure would produce d[a1;a2 ] = 0.1414 and d[b1;b2 ] = 0.2828 . note that the aitchison distance will produce the same value for both pairs : [a1;a2 ] = [b1;b2 ] = 0.9803 , as expected for an adequate distance . note that , for any category j (= 1 , 2 , 3 ) , the ratio between frequencies is the same for the two pairs : 
 a1ja2j = b1jb2j we also note that problems occur if a frequency of 0 is listed for a particular class . to address this , we recommend that prior correction be used , commencing the allocation process at a small real number for each category that should be added to the observed absolute frequency . as an analogy to bayesian categorical data analysis , we adopt an equally constant for each category , as with the standard strategy . our recommendation is to add 1/k to the absolute frequencies for each category , thereby avoiding the occurrence of a relative frequency of 0 in any category . random  aspect of treatment arm allocation is preserved due to the random sequence in which patients arrive for inclusion in clinical trials . the most important property of the allocation strategy defined here is that we can verify post hoc adherence to the desired strategy . the use of a purely randomized strategy can not be proven after the trial has been concluded . to verify that the order in which the patients entered the experiment was indeed random , we considered the reverse order of the first 259 patients ( phase one ) and 90 patients ( phase two ) . in tables 2 and 3 , it can be seen how close the results from the reverse order are to those obtained for the original order . we can see that more than half of the patients would change arms by reversing the order in which they enter into a phase . in phase one , 130 of the 259 patients would have changed arms if the reverse order had been considered . for phase two , under the reverse order , this article describes a method of computer - based intentional allocation that has the advantage of being flexible , effective , and feasible for the allocation of each consecutive patient , or groups of three patients , in terms of multiple covariates . future studies are still needed to evaluate the effectiveness of this procedure when a large number of covariates are included . the procedure presented here is reliable for the inclusion of up to six compositional covariates with twenty - one possible alternative results . when using this procedure , researchers could include any allocation strategy variables suspected of influencing treatment response . one limitation of the proposed procedure is the need to know the value of each prognostic factor , for each patient entering the study , prior to allocation . consequently , values of prognostic factors that can only be obtained through long - term evaluation can not be included in the model . another issue is the weights given to the allocation factors . for the trial in question , the second author ( the psychiatrist responsible for conducting the trial ) based the choice of variable weights on the evidence levels of the prognostic factors that influence treatment response . although this was an arbitrary decision , it does not favor any allocation tendency that might result in arm imbalance . thus , there is no imbalance that might favor a particular result in terms of treatment response . in conclusion , the procedure described here can be easily adapted to different study designs . the results of the trial , used as illustration , show that the methodology was reliable for the sample tested . there are , however , some reliability issues that require further investigation , such as the inclusion of cases presenting a large number of factors or factors that feature a large number of possible alternative categories . nevertheless , we believe that this paper presents a procedure that will be useful in avoiding imbalance among treatment arms when patient allocation is performed sequentially .
objective : this paper aims to describe and discuss a minimization procedure specifically designed for a clinical trial that evaluates treatment efficacy for ocd patients.method:aitchisons compositional distance was used to calculate vectors for each possibility of allocation in a covariate adaptive method . 
 two different procedures were designed to allocate patients in small blocks or sequentially one-by-one.results:we present partial results of this allocation procedure as well as simulated data . in the clinical trial for which this procedure was developed , successful balancing between treatment arms was achieved . 
 separately , in an exploratory analysis , we found that if the arrival order of patients was altered , most patients were allocated to a different treatment arm than their original assignment.conclusion:our results show that the random arrival order of patients determine different assignments and therefore maintains the unpredictability of the allocation method . 
 we conclude that our proposed procedure allows for the use of a large number of prognostic factors in a given allocation decision . 
 our method seems adequate for the design of the psychiatric trials used as models . 
 trial registrations are available at clinicaltrials.gov nct00466609 and nct00680602 .