Model Type III Sum of Squares [General Sta­tis­tics]

posted by ElMaestro  – Denmark, 2018-12-23 18:21  – Posting: # 19709
Views: 681

Hellobi :-D

» 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 SS0).
Next we add Subject to the model. Now the residual goes really a lot down (SS1). At this point we may say SSsubj=SS0-SSsubj. There will be N-1 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 (SSsubj,seq=SSsubj), others will present it as a really low number equal to convergence precision (like 2e-16 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 N-2 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.:-D

if (3) 4

x=c("Foo", "Bar")
typeof(b[,1]) ##aha, integer?
b[,1]+1 ##then let me add 1

Best regards,

"(...) targeted cancer therapies will benefit fewer than 2 percent of the cancer patients they’re aimed at. That reality is often lost on consumers, who are being fed a steady diet of winning anecdotes about miracle cures." New York Times (ed.), June 9, 2018.

Complete thread:

 Mix view
Bioequivalence and Bioavailability Forum |  Admin contact
19,302 posts in 4,102 threads, 1,317 registered users;
online 16 (2 registered, 14 guests [including 7 identified bots]).

Restlessness is discontent –
and discontent is the first necessity of progress.
Show me a thoroughly satisfied man –
and I will show you a failure.    Thomas Alva Edison

BEBAC Ing. Helmut Schütz