- Calculate three sum of squares terms -- SSA, SSB, and SSAB -- and their sum:
SST = SSA + SSB + SSAB.- Calculate fraction of variation explained by A, B, and AB:
SSA/SST, SSB/SST, and SSAB/SST
The sum of errors is always 0.
The sum of squared errors (SSE) is not:
Recall last sign table:
Sum of errors for experiment 1 = e_{11} + e_{12} +e_{13}
= 0 + 3 - 3
= 0.
SSE for all experiments = 0^2 + 3^2 + (-3)^2 + ... + 4^2 = 102
SSY = sum_{i,j} y_{ij}^2
SS0 = (2^2)r(q_0^2)
Computing SSA, SSB, and SSB is easy: (2^2)r(q_A^2), etc.
But computing SSE from definition is painful -- lots of terms to sum!
Instead, compute SSE from other SS* terms (SST, SSA, SSB, SSAB) and from SS0:
SST = SSA + SSB + SSAB + SSE
SST = SSY - SS0
Thus SSE = SSY - (SS0 + SSA + SSB + SSAB)
- Compute SSY
- Compute SS0, SSA, SSB, SSAB
- Compute SSE from preceeding SS* terms
- Compute SST = SSY - SS0
- Compute SSA/SST, SSB/SST, SSAB/SST, and SSE/SST
For the memory-cache study.
SSY = 15^2 + 18^2 + 12^2 + 45^2+... = 27,204 SSO = (2^2)r(q_0^2) = 4*3*41^2 = 20,172 SSA = (2^2)r(q_A^2) = 4*3*21.5^2 = 5,547 SSB = (2^2)r(q_B^2) = 4*3*9.5^2 = 1,083 SSAB = (2^2)r(q_AB^2) = 4*3*5^2 = 300 SSE = SSY - (SS0+SSA+SSB+SSAB) = 102 SST = SSY - SS0 = 7,032Thus:
- Total variation due to A = SSA/SST = 5547/7032 = 78.9%
- Total variation due to B = SSB/SST = 15.4%
- Total variation due to interaction AB = SSAB/SST = 4.3%
- The remaining 1.4% is due to experimental error.