Obinoscopy ★ USA, 20181216 07:58 (edited by Obinoscopy on 20181216 10:42) Posting: # 19695 Views: 2,441 

Hi Guys, I have been looking at the SAS outputs of several Bioequivalence Studies. The statistical analysis of the several BE experiment was done using PROC GLM effect ANOVA model with main effect of treatment, period, sequence and subjects nested within sequence as fixed effects. Most of them are Balanced 2x2x2 BE designs. Now the issue is that I noticed that the Type III Sum of Squares of the Model is not always equal to the sum of the individual Sum of Squares of the various main effects (treatment, period, sequence and subject nested with sequence) for the SAS Outputs I've looked at. I've checked this several times and keep finding out that I don't get the Model SS if I add the various SS of the main effects. But the df for the Model is always equal to the sum of the dfs of the main effects. My rudimentary knowledge of ANOVA is that they are supposed to be the same (both sum of SSs and dfs) . What could be the cause of the discrepancy in sum of SSs? Is it because we assumed in this model that there are no interactions? Regards, — Scopy 
ElMaestro ★★★ Belgium?, 20181216 19:49 @ Obinoscopy Posting: # 19696 Views: 2,270 

Hi Obi, » Now the issue is that I noticed that the Type III Sum of Squares of the Model is not always equal to the sum of the individual Sum of Squares of the various main effects (treatment, period, sequence and subject nested with sequence) for the SAS Outputs I've looked at. This is true and that is how type III works. It is not because of interactions (these are in your model if you want them or they are out if you don't). Imagine you have factors A and B and C in your model. You get the type III SS for factor A by looking at the residual SS in a model with A, B and C and comparing it with a model with only B and C. The difference between the two residual SS's is your type III SS for A. And so forth. Now, in a design where "subject is nested in sequence" you will see that, technically, the two possible sequence columns (of which some are redundant and removed in the fullrank matrix) are equal to all subject columns. So if you have a model with subject, period and treatment, the type III SS for sequence is in principle nil. But then the software may as a courtesy extended to good and faithful users take out subject when trying to figure out the type III SS for sequence, so to get the type III for sequence, you compare the residual from a model with only period and treatment, to the residual from a model with everything. And so forth. It follows a strict set of logical rules. Try and look at type I SS and specify subject before sequence, and sequence before subject and see what happens . Play around. Type I SS's will add up (the relative drawback is that the SS's for each factor can depend on which factors specified before others), but type III SS's won't necessarily add up. — I could be wrong, but... Best regards, ElMaestro 
Obinoscopy ★ USA, 20181218 19:10 @ ElMaestro Posting: # 19697 Views: 2,137 

Thanks so much ElMaestro. I think I have an improved grasp of the different SS Types now thanks to you. I also want to use the Venn Diagram when looking at the method of calculating the SSs. I am imagining a Venn Diagram with Factors A, B and C pictured as spheres that sometimes overlap. For Type I, if I want to determine the SS for factor A first then we have SS(A). Then if the next is factor B, we have to remove the component of A in B which gives SS(B∩A'). And finally for C, we have SS(C∩A'∩B'). For Type III, we just do SS(A), SS(B) and SS(C). or something in that light. I don't know if it's the right way to imagine it. However I want to confirm the statement that "SS results for Type I and III are the same for a balanced design". Is that true? I read it somewhere. Though I noticed they mentioned orthogonality as well. » Try and look at type I SS and specify subject before sequence, and sequence before subject and see what happens . Play around. Type I SS's will add up (the relative drawback is that the SS's for each factor can depend on which factors specified before others), but type III SS's won't necessarily add up. I will definitely play around :). Thanks. Regards, — Scopy 
ElMaestro ★★★ Belgium?, 20181218 21:32 @ Obinoscopy Posting: # 19698 Views: 2,140 

Hello Obi, » I also want to use the Venn Diagram when looking at the method of calculating the SSs. I am imagining a Venn Diagram with Factors A, B and C pictured as spheres that sometimes overlap. » » For Type I, if I want to determine the SS for factor A first then we have SS(A). Then if the next is factor B, we have to remove the component of A in B which gives SS(B∩A'). And finally for C, we have SS(C∩A'∩B'). » » For Type III, we just do SS(A), SS(B) and SS(C). or something in that light. I don't know if it's the right way to imagine it. I can't follow what you are saying here. Type III SS for a factor A is essentially the SS for A given B and C in the model. I guess you might refer to that as SS(AB∩C), but check it with someone who understands statistics. I don't. » » However I want to confirm the statement that "SS results for Type I and III are the same for a balanced design". Is that true? » Correct, but note the meaning of balance may differ for other designs; traditionally in BE balance is when you have an equal number of evaluable completers in RT and TR and when the analysis only involves those evaluable completers. » I read it somewhere. Though I noticed they mentioned orthogonality as well. » Orthogonality is a quite abstract term and entire books are written about it. In this context it means you can partition the variability onto the factors of the design. FDA used the term in a presentation some years ago about in vivo and in vitro factors that affect bioequivalence testing for OIPs and suddenly everybody was talking about orthogonality in a grandiose hodgepodge of confusion. The community has not recovered yet. If you mention something that could hypothetically affect the outcome of a BE trial or treatment success (like inhaler training, or lactose grade, or an image of mickey mouse printed on the side of the inhaler to make it appealing to children) people will unhesitatingly ask if that's an orthogonal factor. — I could be wrong, but... Best regards, ElMaestro 
Obinoscopy ★ USA, 20181220 20:42 @ ElMaestro Posting: # 19701 Views: 2,091 

Thanks so much ElMaestro. » Type III SS for a factor A is essentially the SS for A given B and C in the model. I guess you might refer to that as SS(AB∩C), OK, so that implies that Type III for factor B and C becomes SS(BA∩C) and SS(CA∩B) respectively? How about Type I SS for factors A, B and C (in that order)? Would it be SS(A), SS(BA) and SS(CA∩B) respectively? » but check it with someone who understands statistics. I don't. I think your knowledge of statistics is fine enough for me. The statisticians around me are not in the medical field thus they end up confusing me most times. » Correct, but note the meaning of balance may differ for other designs; traditionally in BE balance is when you have an equal number of evaluable completers in RT and TR and when the analysis only involves those evaluable completers. OK that's true. This could possibly be part of the reason why Type I and type III SS are not the same even in a balanced BE design. » Orthogonality is a quite abstract term and entire books are written about it. In this context it means you can partition the variability onto the factors of the design. FDA used the term in a presentation some years ago about in vivo and in vitro factors that affect bioequivalence testing for OIPs and suddenly everybody was talking about orthogonality in a grandiose hodgepodge of confusion. » The community has not recovered yet. If you mention something that could hypothetically affect the outcome of a BE trial or treatment success (like inhaler training, or lactose grade, or an image of mickey mouse printed on the side of the inhaler to make it appealing to children) people will unhesitatingly ask if that's an orthogonal factor. Well, I guess I shouldnt wake up the orthogonal monster — Scopy 
ElMaestro ★★★ Belgium?, 20181221 03:49 @ Obinoscopy Posting: # 19702 Views: 2,059 

Hello obi, » » Type III SS for a factor A is essentially the SS for A given B and C in the model. I guess you might refer to that as SS(AB∩C), » » OK, so that implies that Type III for factor B and C becomes SS(BA∩C) and SS(CA∩B) respectively? This would be my best guess yes, but please do not rely on anything I say in relation to anything. Or suffer the consequences » How about Type I SS for factors A, B and C (in that order)? Would it be SS(A), SS(BA) and SS(CA∩B) respectively? As above. » OK that's true. This could possibly be part of the reason why Type I and type III SS are not the same even in a balanced BE design. Please explain. When there is balance then the type I and type III SS should be the same in these BE trials, shouldn't they? Your Venn diagram should in my expectation have no overlapping circles. — I could be wrong, but... Best regards, ElMaestro 
Obinoscopy ★ USA, 20181223 16:44 @ ElMaestro Posting: # 19708 Views: 2,010 

Hi ElMaestro, » Please explain. When there is balance then the type I and type III SS should be the same in these BE trials, shouldn't they? Your Venn diagram should in my expectation have no overlapping circles. Now I'm more confused :( This question you asked was one of the very reason I created this thread. I had thought that for a balanced BE design, the Type I SS for the different factors should be exactly the same as the Type III SS for those factors. Also I had thought that if the above paragraph is true, then it should mean that the sum of the Type I SS of the different factors should be equal to the sum of the Type III SS which is in turn should be equal to the SS total for a balanced BE design. I created this thread because the statement in the above paragraph was not what I observed for Type III SS in the several SAS outputs I looked at. The statement of yours that almost made me understand the reason for the discrepancy was that what we consider balanced ANOVA in a BE design is not the way the NonBE designs see theirs. — Scopy 
ElMaestro ★★★ Belgium?, 20181223 18:21 @ Obinoscopy Posting: # 19709 Views: 2,041 

Hellobi » Now I'm more confused :( » This question you asked was one of the very reason I created this thread. » I had thought that for a balanced BE design, the Type I SS for the different factors should be exactly the same as the Type III SS for those factors. I think you may be playing around with the random statement in SAS? Let us look at (balanced )type I SS for 22BE where we fit factors Subject and Sequence with an intercept (and we disregard period and treatment for purpose of illustration): First we do the intercept; it is the mean of everything. In the absence of the model "this mean through everything" is our best explanation of the observed data. From this we collect the null SS (let us say SS_{0}). Next we add Subject to the model. Now the residual goes really a lot down (SS_{1}). At this point we may say SS_{subj}=SS_{0}SS_{subj}. There will be N1 columns (DF's) for Subject; the reason it is not N is that all subjects columns add up to exactly the column for intercept. Now we add Sequence to the model. But hey, there are two sequences, and the two columns would both add up to the intercept. So we have at max one sequence column in play. But hey, double whammy, subject is nested in sequence, so if we add the subject columns for the subjects in TR, they will add up to the putative column for sequence TR. And the same for RT. Now, this means there will be zero df for sequence, if subject is already in the model. Addition of Sequence thus does not add info (does not add variation) under these circumstances. Some stats packages will present it as a zero (SS_{subj,seq}=SS_{subj}), others will present it as a really low number equal to convergence precision (like 2e16 or something really small) and others will simply not present it at all because it is futile. Now try and fit it with sequence and no subject: The two sequence columns would add up to the intercept, therefore we can only add one sequence column and we get one df for sequence. And hey, this means sequence adds info, we get a new residual . And now we add subject. But this time for subject we can only add N2 subject columns, because otherwise linear combinations of some columns would add up to linear combinations of others. Therefore type I SS will add up to the model SS. But if you involve the random statement in SAS then it may (I simply don't know, I am not a SAS user) play clever and try to figure out that if you have sequence after subject, it will default to just sequence when reporting the SS (because no user is looking for nothing when they introduce a factor, right?). This is my best guess where SAS behaviour is concerned.´ and I am not qualified to talk about it with any level of trustworthiness. — I could be wrong, but... Best regards, ElMaestro 
Obinoscopy ★ USA, 20181225 16:56 @ ElMaestro Posting: # 19716 Views: 1,957 

Thanks ElMaestro for your time. You've provided the foundation on which I will build further knowledge on Type I and Type III ANOVA sum of squares. Merry Christmas. — Scopy 