Você está na página 1de 32

Chapter 21: Randomized Complete Block Designs

Lecture 13 April 5, 2006 Psych 791

Slide 1 of 32

Todays Class
s
Overview q Todays Class Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

Blocking. Randomized Complete Block Designs. Our example today will be from SAS: http://v8doc.sas.com/sashtml/stat/chap17/sect4.htm.

s s

Slide 2 of 32

Blocking

Slide 3 of 32

What is Blocking?
s
Overview Blocking q What is Blocking? q Designing a Study q Blocking Criteria q Design, continued q Advantages to Blocking q Disadvantages to Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

The idea of blocking for a variable is to control the levels of a factor that are not normally controlled. This blocking variable will reduce the amount of experimental error variance in the model. It will also increase the validity of your results. For example, if you have a design where one of the factor is gender and do not block for gender. If the experimental groups do not have an equal number of males and females in them, how do you know if the differences are due to the treatment or to gender? The answer is, you dont, so block!!!

s s

Slide 4 of 32

Designing a Study
s
Overview Blocking q What is Blocking? q Designing a Study q Blocking Criteria q Design, continued q Advantages to Blocking q Disadvantages to Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

This chapter deals with a specic design called a Randomized Complete Block Design. Breaking this down:
x x

Block - There is a blocking variable. Complete - Every experimental condition is contained within each blocking level. Randomized - Subjects are randomly assigned to an experimental condition (within block).

Let us suppose that gender is our blocking variable, we determine our experimental conditions, and then as we collect our subjects (an equal amount from each gender), we randomly assign them to a treatment group.

Slide 5 of 32

Blocking Criteria
s
Overview Blocking q What is Blocking? q Designing a Study q Blocking Criteria q Design, continued q Advantages to Blocking q Disadvantages to Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

The purpose of blocking is to sort subjects in groups where each are homogenous with respect to the response variable to make the differences between the groups as great as possible. These are things that are not usually controlled but which you think may have an effect on the outcome variable. There are two types of criteria for which to block:
x

Characteristics of Subjects: For persons: age, income, intelligence, education, attitudes, etc; For something like region of the country: population, average income, etc. Characteristics of the Experiment: observer, time of processing, machine, measuring instrument, batch, etc.

Slide 6 of 32

Design, continued
s
Overview Blocking q What is Blocking? q Designing a Study q Blocking Criteria q Design, continued q Advantages to Blocking q Disadvantages to Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

The design of a blocking criteria really takes some pre-thought. It means that in advance, you think that some variable might have an effect on the outcome response. Usually, it can be drawn from past research. If something was shown to effect the response variable, you can block for it, in a sense control for that variable, to be sure that your experimental factor is really effecting your response.

s s

Slide 7 of 32

Advantages to Blocking
s
Overview Blocking q What is Blocking? q Designing a Study q Blocking Criteria q Design, continued q Advantages to Blocking q Disadvantages to Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

It can provide more precise results. It can accommodate any number of treatments or replications. Do not need equal sample size of treatment level factors. Analysis is simple (really same as in previous chapters). If a particular level of the blocking variable needs to be dropped, it does not ruin the results. Can deliberately induce variability by altering the levels of the blocking variable.

s s s

Slide 8 of 32

Disadvantages to Blocking
s
Overview Blocking q What is Blocking? q Designing a Study q Blocking Criteria q Design, continued q Advantages to Blocking q Disadvantages to Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

If missing observations in a block, analysis becomes complicated. Degrees of freedom for model are reduced because you lose some for the blocking variable. More assumptions... Difcult to make inferences about blocking variable.

s s

Slide 9 of 32

Model for RCBD


s
Overview Blocking Model q Model for RCBD q Model Notes Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

This is the model, should look fairly similar Yij = + i + j + ij

s s s s s

Where: is a constant i constant for the block (row) effects with j constant for treatment effects with ij independent N (0, 2 i = 0

j = 0

Slide 10 of 32

Model Notes
s
Overview Blocking Model q Model for RCBD q Model Notes Fitting the Model ANOVA Table F-test

As you can see, this model is the same as we used for the two-factor design with no interaction term. The only thing that changed is our greek letters, so dont be fooled by the name differences. We will NEVER t a model with an interaction between a blocking variable and another variable. The blocking effect is an essence a way to control the error variance. So, we take out the piece of the error variance associated with the variable so we can concentrate on the effect of the treatment.

s
Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

Slide 11 of 32

Fitting the Model


s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

Fitting the model is done in the same way as we did for the last chapter without the interaction term. We dene our parameters in terms of our s, then we . substitute in our Y Our parameters are: = Y i Y i = Y j Y j = Y

Slide 12 of 32

ANOVA table
s
Overview Blocking Model Fitting the Model ANOVA Table q ANOVA table q Degrees of freedom q Mean Square F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

The ANOVA table wont look any different in terms of the sources of variation and our degrees of freedom. We partition out our SSTO (total sums of squares) into these parts:
x x x

SSBL - Sum of squares for the blocking variable SSTR - Sum of squares for the treatment SSBL.TR - It is a new label for our SSE - it is the interaction sum of squares between blocks and treatment SST O = SSBL + SST R + SSBL.T R

Slide 13 of 32

Degrees of freedom
s
Overview Blocking Model Fitting the Model ANOVA Table q ANOVA table q Degrees of freedom q Mean Square F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

The degrees of freedom associated with each of these sums of squares is as follows:
x x x x

SSBL - df = nb 1 where nb is the number of blocks SSTR - df = r 1 where r is the treatment levels SSBL.TR - df = (nb 1)(r 1) SSTO df = nb r 1

Slide 14 of 32

Mean Square
s
Overview Blocking Model Fitting the Model ANOVA Table q ANOVA table q Degrees of freedom q Mean Square F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

To nd the MS for each effect, take the SS and divide by the df

Slide 15 of 32

What is Important?
s
Overview Blocking Model Fitting the Model ANOVA Table F-test q What is Important? q Testing for Main Effect of Treatment q Test the Blocking Effect? Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

The only important test in this case is as follows: Is there an effect of the treatment? We can test this doing a typically F test using the ANOVA table.

Slide 16 of 32

Testing for Main Effect of Treatment


s
Overview Blocking Model Fitting the Model ANOVA Table F-test q What is Important? q Testing for Main Effect of Treatment q Test the Blocking Effect? Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

Null Hypothesis: H0 : all j = 0 Ha : not all j = 0

or alternatively: H0 : 1 = 2 = . . . = r Ha : not all j equal

To test: F (r 1, (nb 1)(r 1)) = M ST R M SBL.T R

Slide 17 of 32

Test the Blocking Effect?


s
Overview Blocking Model Fitting the Model ANOVA Table F-test q What is Important? q Testing for Main Effect of Treatment q Test the Blocking Effect? Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

You can test the blocking variable, but that usually isnt important to you. It shouldnt matter if the blocking variable is signicant if you are testing the effect of your treatment variable. If you did want to test it, just in case, you would perform a usual F test: M SBL F (nb 1, (nb 1)(r 1)) = M SBL.T R

Slide 18 of 32

Model Fit
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit q Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

Once the model is t, how do we know it is appropriate? Here are some of the signs the model does not t are:
x x x x

Unequal error variance for blocks. Unequal error variance for treatments. Time effect. Block-Treatment Interaction.

s s

Most of these can be done by residual plotting. The interaction effect can be done by mean plotting (or an interaction plot).

Slide 19 of 32

Post-Hoc analysis
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc q Post-Hoc analysis More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up

Good news, all that stuff we learned about testing means is still applicable here (Tukey, Scheff, Bonferroni). Post-hoc tests are done in the same way as were done for the single factor studies. Again, we employ the same methods as a single factor study because the only factor of interest is the treatment. We only have one treatment effect in this model, the blocking effect is only a way to control error variance. I will spare you the formulas again, but they are all on page 904 if you need a refresher.

Slide 20 of 32

Additional Blocking Variable?


s s

What if we want to block on two variables instead of 1? Instead of complicating things, we can trick the model into thinking that there is only one blocking variable and analyze it in the same way. For example, we want to block by gender and age. Two gender groups (M and F). Two age groups (drinking age, below drinking age). We can think of the interaction of these as a single blocking variable with 4 levels: (M DA, M NDA, F DA, F NDA). Since the blocking variable isnt important for our analysis, there is no reason to make things more complicated. We arent going to test for the effect anyway, right?

s s s s

Slide 21 of 32

Block Replications
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block q Block Replications q Model q Fitting this model More Than One Treatment Design Matrix Wrapping Up

Increasing the replications within each block may lead to an interaction effect between the block and the treatment. We dont want to completely scrap our data, so we adjust the model to t the data. The design is called a generalized randomized block design. The model now contains an interaction term.

s s

Slide 22 of 32

Model
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block q Block Replications q Model q Fitting this model More Than One Treatment Design Matrix Wrapping Up

Add an interaction term Yijk = + i + j + ( )ij + ij

s s s s s s

Where: is a constant i constant for the block (row) effects with j constant for treatment effects with i = 0

j = 0

( )ij constant and sum over both subscripts ij independent N (0, 2

Slide 23 of 32

Fitting this model


s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block q Block Replications q Model q Fitting this model More Than One Treatment Design Matrix Wrapping Up

This model ts like the two-way ANOVA model, with different notation. The difference will be in the notation and what you want to test. Want to test Treatment Effects.

Slide 24 of 32

Adding a Treatment
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment q Adding a Treatment q Model q Sum of Squares q Degrees of Freedom q F-test Design Matrix Wrapping Up

The models above all assumed that we only had one treatment that we were interested in. How many studies are run nowadays with only one treatment? So, we want to encompass a two factor design with a block. This is actually fairly easy, we take our two factor design model from Tuesday, and add a blocking factor.

s s

Slide 25 of 32

Model
s
Overview Blocking Model

Adding a Blocking Effect (and changing subscripts) Yijk = + i + j + k + ( )jk

s
Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment q Adding a Treatment q Model q Sum of Squares q Degrees of Freedom q F-test Design Matrix Wrapping Up

Where: is a constant j constant for treatment effects with j constant with k constant with
j ( )jk j

s s s s s s

j = 0

i = 0 j = 0
k ( )jk

= 0 and =0

=0

k ( )jk

Slide 26 of 32

Sum of Squares
s
Overview Blocking Model

Our Sum of Squares partitions in the normal way: SST O = SSBL + SST R + SSBL.T R

s
Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment q Adding a Treatment q Model q Sum of Squares q Degrees of Freedom q F-test Design Matrix Wrapping Up

But now we are going to partition our SSTR further into components associated with each effect SST R = SSA + SSB + SSAB

SST O = SSBL + SSA + SSB + SSAB + SSBL.T R

Slide 27 of 32

Degrees of Freedom
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment q Adding a Treatment q Model q Sum of Squares q Degrees of Freedom q F-test Design Matrix Wrapping Up

These are again partitioned in the "usual" way: SSBL - df = nb 1 where nb is the number of blocks SSTR - df = r 1 where r is the treatment levels
x x x x

s s

This gets further partitioned SSA df = a 1 SSB df = b 1 SSAB df = (a 1)(b 1)

s s

SSBL.TR - df = (nb 1)(r 1) SSTO df = nb r 1

Slide 28 of 32

F-test
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment q Adding a Treatment q Model q Sum of Squares q Degrees of Freedom q F-test Design Matrix Wrapping Up

For each of the three treatment effects, we then take the MS associated with each effect and divide by our MSE (in this case MSBL.TR) We have the same null hypothesis, the same F-test, the same calculation of the degrees of freedom, etc.

Slide 29 of 32

Design Matrix
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix q Design Matrix Wrapping Up

As things get more and more complicated, it takes longer to write out the design matrix So, lets consider a simple study, what would be the design matrix if we had two blocks with one treatment that had 2 levels?

Slide 30 of 32

Final Thought
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up q Final Thought q Next Class

Today we found out how we can control for additional factors in an experiment by adding a blocking factor to our analysis. The way this works is by partitioning variance due to the blocking factor out of the error variance. In essence, this is what will happen when our blocking factor becomes a continuous variable (next chapter). ANCOVA is coming.

Slide 31 of 32

Next Time
s
Overview Blocking Model Fitting the Model ANOVA Table F-test Model Fit Post-Hoc More Than One Block More Than One Replication in Block More Than One Treatment Design Matrix Wrapping Up q Final Thought q Next Class

Chapter 22 (ANCOVA - Analysis of Covariance). No class next week.

Slide 32 of 32

Você também pode gostar