5.3 - The Additive Model: Ketone Example

In a factorial design, we first look at the interactions for significance. In the case where the interaction is not significant, we can drop the term from our model and end up with an "Additive Model".

For a two-factor factorial, the model we initially consider (as we have discussed in Section 5.1) is:

\(Y_{ij}=\mu+\alpha_i+\beta_j+(\alpha\beta)_{ij} +\epsilon_{ijk}\)

If the interaction is found to be non-significant, then the model reduces to:

\(Y_{ij}=\mu+\alpha_i+\beta_j+\epsilon_{ijk}\)

Here we can see that the response variable is simply a function of adding the effects of the two factors.

Ketones in Urine Section

Consider a study designed to evaluate two methods for measuring the amount of ketones in urine. A large volume of artificial urine served as a starting point for the experiment. The urine was divided into three portions, each had artificial ketones added to it. Three different ketone levels were used. The amount of ketones were then measured by one of the two methods from samples of the urine. This type of experiment is commonly used to compare the sensitivity of different methods.

The amount of ketones detected in each sample was recorded and is presented in the table below.  

 
  Measurement Method
Method 1 Method 2
Ketone Level 1 2 3 1 2 3
  16.9 38.7 81.3 9.9 31.7 75.2
  17.2 44.5 80.9 10.2 32.2 73.5
  16.7 42.4 83.1 11.3 30.5 74.8

The model was run as a two-factor factorial and produced the following results:

Type 3 Analysis of Variance
Source DF Sum of Squares Mean Square Expected Mean Square Error Term Error DF F Value Pr > F
method 1 291.208889 291.208889 Var(Residual) + Q(method, method*level) MS(Residual) 12 143.73 <.0001
level 2 12797 6398.606667 Var(Residual) + Q(level, method*level) MS(Residual) 12 3158.07 <.0001
method*level 2 12.964444 6.482222 Var(Residual) + Q(method*level) MS(Residual) 12 3.20 0.0770
Residual 12 24.313333 2.026111 Var(Residual)        

Here we can see that the interaction of method*level was not significant (p-value > 0.05) at a 5% level. We drop the interaction effect from the model and run the additive model. The resulting ANOVA table is:

The Mixed Procedure
Type 3 Analysis of Variance
Source DF Sum of Squares Mean Square Expected Mean Square Error Term Error DF F Value Pr > F
method 1 291.208889 291.208889 Var(Residual)+Q(method, method) MS(Residual) 14 109.37 <.0001
level 2 12797 6398.606667 Var(Residual) + Q(level,level) MS(Residual) 14 2403.05 <.0001
Residual 14 37.277778 2.662698 Var(Residual)        

The Error SS is now 37.2778, which is the sum of the interaction SS and the error SS of the model with the interaction. The df values were also added the same way. This example shows that any term not included in the model gets added into the error term, which may erroneously inflate the error especially if the impact of the excluded term on the response is not negligible.

method Least Squares Means

method Estimate Standard Error DF t Value Pr >|t| Alpha Lower Upper
1 46.8556 0.5439 14 86.14 <.0001 0.05 45.6890 48.0222
2 38.8111 0.5439 14 71.35 <.0001 0.05 37.6445 39.9777
1 2 46.85638.811method Estimate ketone Tukey Grouping for LS-Means of method (Alpha = 0.05) LS-means covered by the same bar are not significantly different.
level Least Squares Means
level Estimate Standard Error DF t Value Pr >|t| Alpha Lower Upper
1 13.7000 0.6662 14 20.57 <.0001 0.05 12.2712 15.1288
2 36.6667 0.6662 14 55.04 <.0001 0.05 35.2379 38.0955
3 78.1333 0.6662 14 117.29 <.0001 0.05 76.7045 79.5621

Here we can see that the amount of ketones detected in a sample (the response variable) is the overall mean PLUS the effect of the method used PLUS the effect of the ketone amount added to the original sample. Hence, the additive nature of this model.

First, load and attach the keytone data in R. Note we specify method and level as factors.

setwd("~/path-to-folder/")
ketone_data<-read.table("ketone_data.txt",header=T,sep ="\t")
attach(ketone_data)
method = as.factor(method)
level = as.factor(level)

We then run the crossed model and obtain the ANOVA table.

options(contrasts=c("contr.sum","contr.poly"))
lm1 = lm(ketone ~ method*level) 
aov3_1 = car::Anova(lm1, type=3) 
print(aov3_1,digits=7)
Anova Table (Type III tests)

Response: ketone
               Sum Sq Df     F value     Pr(>F)      
(Intercept)  33024.50  1 16299.45160 < 2.22e-16 *** 
method         291.21  1   143.72800 4.8871e-08 *** 
level        12797.21  2  3158.07294 < 2.22e-16 *** 
method:level    12.96  2     3.19934   0.076978 .   
Residuals       24.31 12                        
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Removing the insignificant interaction, we obtain ANOVA table of the additive model.

lm2 = lm(ketone ~ method + level) 
aov3_2 = car::Anova(lm2, type=3) 
print(aov3_2,digits=7)
Anova Table (Type III tests)

Response: ketone
              Sum Sq Df    F value     Pr(>F)     
(Intercept) 33024.50  1 12402.6438 < 2.22e-16 ***
method        291.21  1   109.3661 5.3505e-08 *** 
level       12797.21  2  2403.0535 < 2.22e-16 *** 
Residuals      37.28 14                        
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

We can then examine the LS mean estimates of both the method and level effects individually.

aov1 = aov(lm2)
lsmeans_method = emmeans::emmeans(aov1,~method) 
lsmeans_method
method emmean    SE df lower.CL upper.CL  
1        46.9 0.544 14     45.7       48  
2        38.8 0.544 14     37.6       40

Results are averaged over the levels of: level 
Confidence level used: 0.95 

lsmeans_level = emmeans::emmeans(aov1,~level) 
lsmeans_level
level emmean    SE df lower.CL upper.CL  
1       13.7 0.666 14     12.3     15.1  
2       36.7 0.666 14     35.2     38.1  
3       78.1 0.666 14     76.7     79.6

Results are averaged over the levels of: method 
Confidence level used: 0.95