# [BioC] RE: Bioconductor Digest, Vol 8, Issue 34

Baker, Stephen Stephen.Baker at umassmed.edu
Wed Oct 22 17:21:41 MEST 2003

```SAS describes their approach as follows:

...The normal equations are solved using a modified sweep routine that
produces a generalized (g2) inverse (X'X)^- and a solution b =
(X'X)^-X'y (Pringle and Raynor 1971)(1).

For each effect in the model, a matrix L is computed such that the rows
of L are estimable. Tests of the hypothesis are then made by first
computing

SS(LB=0)=(Lb)'(L(X'X)^-L')^-1(Lb)

and then computing the associated F value using the mean squared error.
...

and

...The Type III hypotheses are precisely the hypotheses being tested by
programs that reparameterize using the usual assumptions (for example,
all parameters for an effect summing to zero). When no missing cells
exist in a factorial model, Type III SS coincide with Yates' weighted
squares-of-means technique. When cells are missing in factorial models,
the Type III SS coincide with those discussed in Harvey (1960)(2) and
Henderson (1953)(3). ...

(1). Pringle, R.M. and Raynor, A.A. (1971), Generalized Inverse Matrices
with Applications to Statistics, New York: Hafner Publishing Co.

(2). Harvey, W. R. (1960),"Least-Squares Analysis of Data with Unequal
Subclass Frequencies," USDA, Agriculture Research Service, ARS 20-8,
reprinted with corrections as ARS H-4, 1975, also reprinted 1979.

(3) Henderson, C. R. (1953), "Estimation of Variance and Covariance
Components," Biometrics, 9, 226 -252.

----------------------------------------------------------------------

Message: 1
Date: Tue, 21 Oct 2003 08:09:10 -0400
From: "Subramanian Karthikeyan" <Subramanian_Karthikeyan at hc-sc.gc.ca>
Subject: [BioC] Type III Sum of Squares Calculation
To: bioconductor at stat.math.ethz.ch
Message-ID: <OF41129209.407D90E2-ON85256DC6.00429D83 at hc-sc.gc.ca>
Content-Type: text/plain; charset=us-ascii

HI All:

Can anyone give me the formulae/steps for calculating the type III sum
of squares for an unbalanced 2-way ANOVA design?  Eg. we are looking at
8 treatments x 4 doses, with unequal numbers of replications within the
groups.  I really need the stepwise calculation, as I would try to put
it in my own code (possibly in Visual Basic) to automate the task.

Thanks very much.

Karth.

```
{"ft_lang_label":"__label__en","ft_lang_prob":0.8026096,"math_prob":0.80853814,"size":2332,"snap":"2021-21-2021-25","text_gpt3_token_len":652,"char_repetition_ratio":0.10309278,"word_repetition_ratio":0.006006006,"special_character_ratio":0.30231562,"punctuation_ratio":0.19361702,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.9907469,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-05-07T19:42:44Z\",\"WARC-Record-ID\":\"<urn:uuid:f1071c20-09c2-4d77-bc27-cbc30be3e2ad>\",\"Content-Length\":\"4903\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:8edfd4bb-d079-4e49-8ad2-6632e5cbeb26>\",\"WARC-Concurrent-To\":\"<urn:uuid:c35de6c5-82cb-4d2e-a2f6-ddc05d4e4af6>\",\"WARC-IP-Address\":\"129.132.119.195\",\"WARC-Target-URI\":\"https://stat.ethz.ch/pipermail/bioconductor/2003-October/002770.html\",\"WARC-Payload-Digest\":\"sha1:Q4H7UEHQ2XEDPTEFIGB6WMS5NHDBRJB5\",\"WARC-Block-Digest\":\"sha1:NT3XVWRS72TC2LUJ4A64Y67SLOE4M3CA\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-21/CC-MAIN-2021-21_segments_1620243988802.93_warc_CC-MAIN-20210507181103-20210507211103-00405.warc.gz\"}"}