1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter...

45
dB dB dB dB 1 STA 536 – Experiments with More Than One Factor dB dB dB dB Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block design. 3.3 Two-way layout. 3.5 multi-way layout. 3.6 Latin square design. 3.7 Graeco-Latin square design. 3.8 Balanced incomplete block design. 3.10 Analysis of covariance (ANCOVA).

Transcript of 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter...

Page 1: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 1STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Experiments with More Than One Factor (Chapter 3)

3.1 Paired comparison design. 3.2 Randomized block design. 3.3 Two-way layout. 3.5 multi-way layout. 3.6 Latin square design. 3.7 Graeco-Latin square design. 3.8 Balanced incomplete block design. 3.10 Analysis of covariance (ANCOVA).

Page 2: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 2STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

3.1 Paired Comparison Design Example: Sewage Experiment Objective : To compare two methods MSI and SIB for

determining chlorine content in sewage effluents; y = residual chlorine reading.

Experimental Design: Eight samples were collected at different doses and contact times. Two methods were applied to each of the eight samples. It is a paired comparison design because the pair of treatments are applied to the same samples (or units).

Experimental Design: Eight samples were collected at different doses and contact times. Two methods were applied to each of the eight samples. It is a paired comparison design because the pair of treatments are applied to the same samples (or units).

Mean of d

=0.4138

Page 3: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 3STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Paired Comparison Design vs. Unpaired Design Paired Comparison Design : Two treatments are

randomly assigned to each block of two units. Can eliminate block-to-block variation and is effective if such variation is large. Examples : pairs of twins, eyes, kidneys, left and

right feet. (Subject-to-subject variation much larger than

within-subject variation).

Unpaired Design : Each treatment is applied to a separate set of units, or called the two-sample problem. Useful if pairing is unnecessary; also it has more degrees of freedom for error estimation. An unpaired design is a completely randomized

design (i.e., one-way layout)

Page 4: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 4STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Paired t-tests

Page 5: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 5STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Unpaired t-tests

Page 6: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 6STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Analysis Results : t-tests

Unpaired t-test fails to declare significant difference because its denominator 2.0863 is too large.

Why ? Because the denominator contains the sample-to-sample

variation component.

The p-values areThe p-values are Wrong analysis

Wrong analysis

Page 7: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 7STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Paired or Unpaired?

Which design is more powerful? The answer depends If there is a large sample to sample

variation, a paired design is more effective.

Otherwise, an unpaired design is more effective.

Recall: For blocking to be effective, the units should be arranged so that the within-block variation is much smaller than the between-block variation.

Page 8: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 8STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Alternative analysis using ANOVA and F test

Wrong to analyze by ignoring pairing. A better explanation is given by ANOVA.

F-statistic in ANOVA for paired design equals ; similarly, F-statistic in ANOVA for unpaired design equals . Data can be analyzed in two equivalent ways.

In the correct analysis (Table 2), the total variation is decomposed into three components; the largest one is the sample-to-sample variation (its MS = 34.77). In the unpaired analysis (Table 3), this component is mistakenly included in the residual SS, thus making the F-test powerless.

Page 9: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 9STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Conclusion: Both the treatment variable (method) and the blocking variable (sample) are significant.

Conclusion: Both the treatment variable (method) and the blocking variable (sample) are significant.

(Wrong) Conclusion: the treatments (method) are not significant different.

(Wrong) Conclusion: the treatments (method) are not significant different.

Page 10: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 10STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

3.2 Randomized Block Design

Recall the principles of blocking and randomization in Chapter 1. In a randomized block design (RBD), k treatments are randomly assigned to each block (of k units); there are in total b blocks. Total sample size N = bk.

Paired comparison design is a special case with k = 2. (Why ?)

Recall that in order for blocking to be effective, the units within a block should be more homogeneous than units between blocks.

Page 11: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 11STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

2.2 Randomized Block Design Example

Objective : To compare four methods for predicting the shear strength for steel plate girders (k = 4,b = 9).

Page 12: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 12STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Model and Estimation

The zero-sum constraints

Page 13: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 13STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

ANOVA

Page 14: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 14STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Testing and Multiple Comparisons

Page 15: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 15STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Simultaneous Confidence Intervals

How about the Bonferroni method?

Page 16: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 16STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

The F statistic in (7) has the value (1.514/3)/(0.166/24)= 73.03.

Therefore, the p-value for testing the difference between methods is Prob(F(3,24) > 73.03)=0.00.

The small p-value suggests that the methods are different after block (girder) effects are adjusted.

Analysis of Girder Experiment : F test

Page 17: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 17STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Analysis of Girder Experiment : Multiple Comparisons

Page 18: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 18STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Another example: penicillin yield experiment

Data from a randomized block experiment in which a process of the manufacture of penicillin was investigated.

Want to try 4 variants of the process, called treatments A, B , C, D.

Yield is the response. The properties of an important raw material varied

considerably, and this might cause considerable differences in yields.

A blend of the material could be made sufficient to make 4 runs.

Each blend forms a block. The 4 treatments were run randomly within each block; see

the superscripts. Note that the randomization is restricted within the blocks.

Page 19: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 19STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Another example: penicillin yield experiment - DATA

Page 20: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 20STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Data penicillin; input blend $ x1-x4; y=x1; treatment="A"; output; y=x2; treatment="B"; output; y=x3; treatment="C"; output; y=x4; treatment="D"; output;cards;Blend1 89 88 97 94Blend2 84 77 92 79Blend3 81 87 87 85Blend4 87 92 89 84Blend5 79 81 80 88;

proc GLM; class blend treatment; model y=blend treatment;run;

Page 21: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 21STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

SAS Output

The blocking variable (blend) is significant at 5% level; the treatments are not different after block effects are adjusted.

Page 22: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 22STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Wrong analysis ignoring blockingproc GLM; class blend treatment;

model y=treatment;

run;

Page 23: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 23STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

3.3 Two-way layout

This is similar to RBD. The only difference is that here we have two treatment factors instead of one treatment factor and one block factor.

Interested in assessing interaction effect between the two treatments.

In blocking, block×treatment interaction is assumed negligible.

Page 24: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 24STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Bolt experiment Objective: To determine what factors affect the torque

values. Torque is the work (i.e., force×distance) required to

tighten a locknut. Two experimental factors:

type of plating: heat treated (HT), cadmium and wax plated (C&W), phosphate and oil plated (P&O)

test medium: mandrel, bolt Data are the torque values for 10 locknuts for each of

the six treatments.

Page 25: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 25STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

two-way layout, which involves two treatment factors.

In general, a two-way layout for two factors (A has I levels and B has J levels) has IJ factor level combinations. Each combination is a treatment.

Suppose that the number of replicates is n, and for each replicate, IJ units should be randomly assigned to the IJ treatments.

Total IJn observations The linear model for the two-way layout is

Page 26: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 26STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Constrains

The interpretations of the parameters and estimates depend on the constraints.

Page 27: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 27STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Estimates Under zero-sum constrains

Estimates under baseline constrains

What are the fitted values?

Page 28: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 28STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

The ANOVA decomposition:

Page 29: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 29STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

ANOVA

Page 30: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 30STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Tests

Page 31: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 31STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Analysis of Bolt Experiment

Conclusions: Both factors and their interactions are significant. Multiple comparisons of C&W, HT and P&O can be performed by using Tukey method with k = 3 and 54 error df’s.

Another method is considered in the following pages using regression

Page 32: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 32STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Comparison with randomized block design

RBD has one blocking factor and one experimental factor

A two-way layout studies two experimental factors

In a 2-way layout, randomization is applied to all IJ units.

In a RBD, randomization is applied within each block.

The blocks represent a restriction on randomization.

Page 33: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 33STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Two-way layout

For an unreplicated experiment, n = 1 and there is not enough degrees of freedom for estimating both the interaction effects

The SSAB should be used as the residual sum of squares. Alternatively, we can use the following Tukey’s “one-

degree of freedom for non-additivity” to test interaction effects:

where is an unknown constant. If there is no interaction effects, should be zero. This method can also be used to test if there is an interaction effect between treatments and blocks in a RBD.

Page 34: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 34STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Practical modeling and estimating the effects

Qualitative factor: baseline constraints are easy to interpret.

Quantitative factor: orthogonal polynomial contrasts are easy to interpret.

Page 35: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 35STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Two Qualitative Factors

Page 36: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 36STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Regression Model (continued)

for one replicate

Page 37: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 37STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Regression Model (continued)Interpretation of parameters

Page 38: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 38STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Regression Analysis Results

Page 39: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 39STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Adjusted p Values

Page 40: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 40STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Box-Whisker Plot : Bolt Experiment

The plot suggests that the constant variance assumption in (5) does not hold and that the variance of y for bolt is larger than that for mandrel. These are aspects that cannot be discovered by regression analysis alone.

Page 41: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 41STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

An interaction plot shows the mean responses of all treatments. It is a useful tool to see the relationship between two factors.

Page 42: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 42STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

3.5 Multi-Way Layout

Consider a three-way layout (or 3-factor factorial design) A has I levels, B has J levels and C has K levels. There are total IJK treatments, each replicated n times. For each replicate, IJK units are randomly assigned to

the IJK treatments.

The linear model for the three-way layout is:

Page 43: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 43STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

EstimatesLet

where

are the estimates of the parameters under the zero-sum constraints.

Page 44: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 44STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

ANOVA

Page 45: 1 STA 536 – Experiments with More Than One Factor Experiments with More Than One Factor (Chapter 3) 3.1 Paired comparison design. 3.2 Randomized block.

CommandButton1CommandButton1CommandButton1CommandButton1 45STA 536 – Experiments with More Than One Factor

CommandButton1CommandButton1CommandButton1CommandButton1

Multi-Way Layout

Estimation, F test, residual analysis are similar to those for two-way layout.