Exam2.B.3 is used to illustrate one way treatment design with Gaussian observations.

References

  1. Stroup, W. W. (2012). Generalized Linear Mixed Models: Modern Concepts, Methods and Applications. CRC Press.

See also

Examples

#----------------------------------------------------------------------------------- ## Means Model discussed in Example 2.B.3 using DataExam2.B.3 #----------------------------------------------------------------------------------- Exam2.B.3.lm1 <- lm( formula = y~trt , data = DataExam2.B.3 # , subset # , weights # , na.action , method = "qr" , model = TRUE # , x = FALSE # , y = FALSE , qr = TRUE , singular.ok = TRUE , contrasts = NULL # , offset # , ... ) summary(Exam2.B.3.lm1)
#> #> Call: #> lm(formula = y ~ trt, data = DataExam2.B.3, method = "qr", model = TRUE, #> qr = TRUE, singular.ok = TRUE, contrasts = NULL) #> #> Residuals: #> 1 2 3 4 5 6 #> -0.325 -0.125 1.000 -0.100 -1.275 0.825 #> #> Coefficients: #> Estimate Std. Error t value Pr(>|t|) #> (Intercept) 17.7500 1.0013 17.727 5.95e-05 *** #> trt 1.5750 0.4635 3.398 0.0273 * #> --- #> Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 #> #> Residual standard error: 0.927 on 4 degrees of freedom #> Multiple R-squared: 0.7427, Adjusted R-squared: 0.6784 #> F-statistic: 11.55 on 1 and 4 DF, p-value: 0.02733 #>
#----------------------------------------------------------------------------------- ## Effectss Model discussed in Example 2.B.3 using DataExam2.B.3 #----------------------------------------------------------------------------------- Exam2.B.3.lm2 <- lm( formula = y~0+trt , data = DataExam2.B.3 # , subset # , weights # , na.action , method = "qr" , model = TRUE # , x = FALSE # , y = FALSE , qr = TRUE , singular.ok = TRUE , contrasts = NULL # , offset # , ... ) summary(Exam2.B.3.lm2)
#> #> Call: #> lm(formula = y ~ 0 + trt, data = DataExam2.B.3, method = "qr", #> model = TRUE, qr = TRUE, singular.ok = TRUE, contrasts = NULL) #> #> Residuals: #> 1 2 3 4 5 6 #> 9.818 10.018 3.536 2.436 -6.346 -4.246 #> #> Coefficients: #> Estimate Std. Error t value Pr(>|t|) #> trt 9.182 1.398 6.57 0.00123 ** #> --- #> Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 #> #> Residual standard error: 7.396 on 5 degrees of freedom #> Multiple R-squared: 0.8962, Adjusted R-squared: 0.8754 #> F-statistic: 43.16 on 1 and 5 DF, p-value: 0.001226 #>