The factors in higher-way ANOVAs can again be considered fixed or random, depending on the context of the study. For each factor:

Similar documents
Random and Mixed Effects Models - Part II

Analysis of Variance and Design of Experiments-I

Unit 7: Random Effects, Subsampling, Nested and Crossed Factor Designs

K. Model Diagnostics. residuals ˆɛ ij = Y ij ˆµ i N = Y ij Ȳ i semi-studentized residuals ω ij = ˆɛ ij. studentized deleted residuals ɛ ij =

Stat 217 Final Exam. Name: May 1, 2002

Theorem A: Expectations of Sums of Squares Under the two-way ANOVA model, E(X i X) 2 = (µ i µ) 2 + n 1 n σ2

TWO OR MORE RANDOM EFFECTS. The two-way complete model for two random effects:

PROBLEM TWO (ALKALOID CONCENTRATIONS IN TEA) 1. Statistical Design

Statistics 512: Applied Linear Models. Topic 9

Unbalanced Designs Mechanics. Estimate of σ 2 becomes weighted average of treatment combination sample variances.

Linear models and their mathematical foundations: Simple linear regression

Two-Way Analysis of Variance - no interaction

STAT 526 Spring Midterm 1. Wednesday February 2, 2011

Two or more categorical predictors. 2.1 Two fixed effects

Ch 2: Simple Linear Regression

Outline Topic 21 - Two Factor ANOVA

Confidence Intervals, Testing and ANOVA Summary

Stat 6640 Solution to Midterm #2

Simple Linear Regression

Lecture 10: Experiments with Random Effects

Stat 579: Generalized Linear Models and Extensions

Formal Statement of Simple Linear Regression Model

STAT 525 Fall Final exam. Tuesday December 14, 2010

Contents. TAMS38 - Lecture 6 Factorial design, Latin Square Design. Lecturer: Zhenxia Liu. Factorial design 3. Complete three factor design 4

Lec 1: An Introduction to ANOVA

Lecture 10: Factorial Designs with Random Factors

Review: General Approach to Hypothesis Testing. 1. Define the research question and formulate the appropriate null and alternative hypotheses.

VIII. ANCOVA. A. Introduction

17 Nested and Higher Order Designs

Lec 5: Factorial Experiment

BIOSTATISTICAL METHODS

Chapter 20 : Two factor studies one case per treatment Chapter 21: Randomized complete block designs

If we have many sets of populations, we may compare the means of populations in each set with one experiment.

Analysis of Variance. Read Chapter 14 and Sections to review one-way ANOVA.

Random and Mixed Effects Models - Part III

Chapter 8: Hypothesis Testing Lecture 9: Likelihood ratio tests

ANOVA Situation The F Statistic Multiple Comparisons. 1-Way ANOVA MATH 143. Department of Mathematics and Statistics Calvin College

STAT 705 Chapter 19: Two-way ANOVA

1-Way ANOVA MATH 143. Spring Department of Mathematics and Statistics Calvin College

Analysis of Variance

STAT 705 Chapter 19: Two-way ANOVA

Reference: Chapter 14 of Montgomery (8e)

Statistics For Economics & Business

Summary of Chapter 7 (Sections ) and Chapter 8 (Section 8.1)

Topic 25 - One-Way Random Effects Models. Outline. Random Effects vs Fixed Effects. Data for One-way Random Effects Model. One-way Random effects

3. Design Experiments and Variance Analysis

STA 303H1F: Two-way Analysis of Variance Practice Problems

22s:152 Applied Linear Regression. Take random samples from each of m populations.

20. REML Estimation of Variance Components. Copyright c 2018 (Iowa State University) 20. Statistics / 36

STAT 506: Randomized complete block designs

Two-factor studies. STAT 525 Chapter 19 and 20. Professor Olga Vitek

More about Single Factor Experiments

STAT 705 Chapter 16: One-way ANOVA

Randomized Complete Block Designs Incomplete Block Designs. Block Designs. 1 Randomized Complete Block Designs. 2 Incomplete Block Designs

Topic 17 - Single Factor Analysis of Variance. Outline. One-way ANOVA. The Data / Notation. One way ANOVA Cell means model Factor effects model

Lectures on Simple Linear Regression Stat 431, Summer 2012

iron retention (log) high Fe2+ medium Fe2+ high Fe3+ medium Fe3+ low Fe2+ low Fe3+ 2 Two-way ANOVA

Homework 3 - Solution

Analysis of Variance

Factorial and Unbalanced Analysis of Variance

ANOVA approaches to Repeated Measures. repeated measures MANOVA (chapter 3)

Chapter 11. Analysis of Variance (One-Way)

The Random Effects Model Introduction

Incomplete Block Designs

BIOS 2083: Linear Models

Homework 2: Simple Linear Regression

Simple Linear Regression

Statistics 210 Part 3 Statistical Methods Hal S. Stern Department of Statistics University of California, Irvine

Chapter 12. Analysis of variance

BANA 7046 Data Mining I Lecture 2. Linear Regression, Model Assessment, and Cross-validation 1

THE ANOVA APPROACH TO THE ANALYSIS OF LINEAR MIXED EFFECTS MODELS

MAT2377. Rafa l Kulik. Version 2015/November/26. Rafa l Kulik

General Linear Model (Chapter 4)

We like to capture and represent the relationship between a set of possible causes and their response, by using a statistical predictive model.

Inferences for Regression

Analysis of variance, multivariate (MANOVA)

Lecture 11: Simple Linear Regression

Lecture 4. Random Effects in Completely Randomized Design

Two Factor Completely Between Subjects Analysis of Variance. 2/12/01 Two-Factor ANOVA, Between Subjects 1

A Short Introduction to Curve Fitting and Regression by Brad Morantz

Two-Way ANOVA (Two-Factor CRD)

Fractional Factorial Designs

A Significance Test for the Lasso

22s:152 Applied Linear Regression. There are a couple commonly used models for a one-way ANOVA with m groups. Chapter 8: ANOVA

I i=1 1 I(J 1) j=1 (Y ij Ȳi ) 2. j=1 (Y j Ȳ )2 ] = 2n( is the two-sample t-test statistic.

Lecture 2 Simple Linear Regression STAT 512 Spring 2011 Background Reading KNNL: Chapter 1

1. (Rao example 11.15) A study measures oxygen demand (y) (on a log scale) and five explanatory variables (see below). Data are available as

One-way ANOVA (Single-Factor CRD)

Lecture 3: Linear Models. Bruce Walsh lecture notes Uppsala EQG course version 28 Jan 2012

Variance components and LMMs

G. Nested Designs. 1 Introduction. 2 Two-Way Nested Designs (Balanced Cases) 1.1 Definition (Nested Factors) 1.2 Notation. 1.3 Example. 2.

Factorial ANOVA. Psychology 3256

Regression: Main Ideas Setting: Quantitative outcome with a quantitative explanatory variable. Example, cont.

Lecture 22 Mixed Effects Models III Nested designs

BIOS 2083 Linear Models c Abdus S. Wahed

Multiple Linear Regression

Blocks are formed by grouping EUs in what way? How are experimental units randomized to treatments?

STAT 430 (Fall 2017): Tutorial 8

Topic 29: Three-Way ANOVA

Table 1: Fish Biomass data set on 26 streams

Transcription:

M. Two-way Random Effects ANOVA The factors in higher-way ANOVAs can again be considered fixed or random, depending on the context of the study. For each factor: Are the levels of that factor of direct interest? Or do they just represent some larger population of levels that could have been included? If the study were to be conducted again, would the exact same levels of that factor be used again? Or would other levels be used? 301

Example Potassium measurements across labs Ten commercial laboratories across the UK were chosen by administrators of the National Quality Control Scheme are interested in the differences across labs in measuring potassium in serum samples. Ten serum samples are created, each of which contains a pre-determined quantity of potassium. Each specimen is divided into ten equal portions. One portion from each specimen is sent to each lab in a completely randomized design. 302

Outcome = Predictors = Predictors should be fixed or random? 303

When would labs be considered a fixed factor? When would labs be considered a random factor? 304

Example Inter-rater reliability Studies of HIV+ patients on anti-retroviral treatments are interested in how the treatments may contribute to changes in metabolism, which can lead to changes in body shape. Changes which seem obvious to the eye can be difficult, however, to measure consistently (e.g., increased surface body fat). 305

Design a: Research nursing staff need to be trained to measure sub-scapular skin fold with calipers for an ongoing single-center clinical trial. a patients are randomly chosen; the b nurses measure each patient r times in a randomized order (often r = 1 or r = 2). Fixed or random: Patients? Nurses? 306

Design b: To assist in planning a clinical trial, researchers need to understand how consistently nursing staff can measure sub-scapular skin fold, since there will be several clinical sites once the trial begins. a patients are randomly chosen from the Principle Investigator s clinic and the b nurses on staff there measure each patient r times in a randomized order (again, often r = 1 or r = 2). Fixed or random: Patients? Nurses? 307

Two-way Random Effects Model Y ijk = µ + a i + b j + (ab) ij + ɛ ijk a i iid N(0, σa 2 ) b j iid N(0, σb 2 ) (ab) ij iid N(0, σab 2 ) ɛ ijk iid N(0, σe 2 ) where i = 1,..., a, j = 1,..., b, and k = 1,..., r and a i, b j, (ab) ij, and ɛ ijk are all independent of each other. 308

E[Y ijk ] = Var[Y ijk ] = Note that this is still a model which assumes homoscedasticity across all observations. 309

Cov[Y ijk, Y ij k ] = 310

Cov[Y ijk, Y i jk ] = 311

Cov[Y ijk, Y ijk ] = 312

Based on this model, inter-rater reliability = σ 2 a σ 2 a + σ2 b + σ2 ab + σ2 e intra-rater reliability = σ 2 b σ 2 a + σ 2 b + σ2 ab + σ2 e But watch out interpretation is suspect if σ 2 ab 0!! When a and b are small, we will not be able to estimate the variance components very well. 313

Estimation in PROC GLM Using PROC GLM, mean estimation and sums of squares computation proceed exactly as they did for the fixed effects two-way ANOVA. With random effects, however, expected mean squares will change, and hence F-tests may change as well. ˆµ = Ȳ Var[ˆµ ] = ˆσ2 a a + ˆσ2 b b + ˆσ2 ab ab + ˆσ2 e rab Tests and confidence intervals can be constructed as usual. 314

Testing Source df SS A a 1 rb i(ȳ i Ȳ ) 2 B b 1 ra j(ȳ j Ȳ ) 2 AB (a 1)(b 1) r i j(ȳ ij Ȳ i Ȳ j + Ȳ ) 2 Error (r 1)ab i j (Ȳ ijk Ȳ ij ) 2 Total rab 1 i j (Ȳ ijk Ȳ ) 2 315

Source E[MS] F A B AB Error σe 2 + rbσa 2 + rσab 2 σe 2 + raσ2 b + rσ2 ab σe 2 + rσ2 ab σ 2 e Total 316

To test H 0 : σ 2 ab = 0, reject H 0 at level α if F AB = To test H 0 : σ 2 b = 0, reject H 0 at level α if F B = To test H 0 : σ 2 a = 0, reject H 0 at level α if F A = 317

Point estimates for the variance components are found by setting the observed mean squares equal to the expected mean squares and solving. MSA = σ 2 + rbσ 2 a + rσ 2 ab = MSE + rbσ2 a + rσ 2 ab MSB = σ 2 + raσ 2 b + rσ2 ab = MSE + raσ2 b + rσ2 ab MSA = σ 2 + rσ 2 ab = MSE + rσ2 ab σ 2 ab = MSAB MSE r σ 2 b = MSB MSE r(msab MSE r ) ra σ 2 a = MSA MSE r(msab MSE r ) rb = = MSB MSAB ra MSA MSAB rb 318

ρ = σ 2 b σ 2 a +σ2 b +σ2 ab +σ2 e For all of these parameters, only approximate interval estimates exist, as for the one-way ANOVA. See Neter, Kutner, Nachtsheim, and Wasserman (1996), Chapter 24. 319

Estimation in PROC MIXED As for the one-way random effects ANOVA, PROC GLM doesn t actually fit a two-way random effects ANOVA. It fits a fixed effects ANOVA and then modifies the F-tests shown in the output to correspond to the appropriate expected mean squares. We can use PROC MIXED instead. 320

PROC MIXED DATA=data; CLASS a b; MODEL y = / SOLUTION; RANDOM INT / SUBJ=a SOLUTION; RANDOM INT / SUBJ=b SOLUTION; RANDOM INT / SUBJ=a*b SOLUTION; Estimation is done via REML and testing is done with likelihood ratio tests or Z tests. 321

Using a likelihood ratio test, we can compare, for example, Full model: Y ijk = µ + a i + b j + (ab) ij + ɛ ijk Reduced model: Y ij = µ + a i + b j + ɛ ij We reject H 0 : σ 2 ab = 0 at level α if T = 2(l Reduced l Full ) > q α where l is the log likelihood and q α is??? 322

There is no theory derived for this case. A conservative approach would be to compare T to the α-quantile of a χ 2 1. 323

SAS does offer a Z-test alternative in PROC MIXED by specifying PROC MIXED DATA=dat COVTEST; A z-test is constructed for each variance component: Z = ˆσ 2 V ar[ˆσ 2 ] and we reject H 0 : σ 2 = 0 if z > z α (one-sided test). What is the downside to this test? 324

Diagnostics Diagnostics are carried out as for the one-way random effects ANOVA. 325

Higher-way Random ANOVAs For some higher-way random ANOVAs such as a threeway model, the ANOVA table from PROC GLM shows that some factors cannot be tested. For example, with three factors A, B, and C, E[MSA] = σ 2 e + rσ2 abc + rcσ2 ab + rbσ2 ac + rbcσ2 a but no term in the model has expected mean square σe 2 + rσabc 2 + rcσ2 ab + rbσ2 ac which we would need to write down an F-test for the main effect of A. 326

Thus when using PROC GLM, one or more interactions must be dropped from the model to get a test for A, or the General Linear F-test approach can be used. It is preferable to just use PROC MIXED. Otherwise, all procedures for higher way random ANOVAs are similar to those for the two-way model. 327