4.3 Fitted Effects for Factorial Data. 4.3.1 Fitted Effects for 2-Factor Studies Factor A → I...

27
4.3 Fitted Effects for Factorial Data
  • date post

    19-Dec-2015
  • Category

    Documents

  • view

    225
  • download

    0

Transcript of 4.3 Fitted Effects for Factorial Data. 4.3.1 Fitted Effects for 2-Factor Studies Factor A → I...

4.3 Fitted Effects for Factorial Data

4.3.1 Fitted Effects for 2-Factor Studies

Factor A → I levelsFactor B → J levels

Equal replication, n replicates, in each treatment group.

→ Balanced design.

8. Bauer, Dirks, Palkovic, and Wittmer fired tennis balls out of a “Polish cannon” inclined at an angle of 45 degree, using three different Propellants and two different Charge Sizes of propellant. They observed the distances traveled in the air by the tennis balls. Their data are given in the accompanying table. (Five trials were made for each Propellant/Charge Size combination and the values given are in feet.)

Problem 8: A = charge size with I = 2 levels of 2.5 ml and 5.0 mlB = propellant with J = 3 levels of lighter fluid, gasoline

and carburetor fluidPropellant

Lighter CarburetorFluid Gasoline Fluid

58 50 76 79 90 86 2.5 53 49 84 73 79 82Charge 59 71 86size 5.0 65 59 96 101 107 102

61 68 94 91 91 9567 87 97

First, plot the data!

• As always the first step is to plot the data. Propellants Original Scale

50

60

70

80

90

100

110

120

0 1 2 3 4

Propellant 1=lighter 2=gas 3=carb

Charge = 2.5

Charge = 5.0

Checking for-Effects of factors

Main effects

Interactions-Outliers-Changes in variances

If we have only 2 factors this is relatively easy.

Notations

Notation: ijy = sample mean with A at level i and B at level j

Propellant j = 1 j = 2 j = 3 Charge Lighter Gasoline Carburetor

i = 1 2.5 ml 11y 12y 13y

i = 2 5.0 ml 21y 22y 23y

iy = sample mean for A at level i jy = sample mean for B at level j

y overall mean of all values

Propellant Charge Lighter Gasoline Carburetor

2.5 ml 11y =53.8 12y =76.6 13y =84.6 1y =71.67

5.0 ml 21y =64.0 22y =93.8 23y =98.4 2y =85.4

1y =58.9 2y =85.2 3y =91.5 y =78.53

Since these data are balanced we can find 1y either by averaging all 15 values for the 2.5 ml charge

averaging the averages 1

53.8 76.6 84.671.67

3y

If the number of values in each mean had not been equal, we would need to take a weighted average of these averages to find the overall average of all points.

Since these data are balanced we can find y either by averaging all 30 values averaging the averages

53.783

5.912.858.5853.78

2

4.8567.71

ory

0 1 2 3 440

50

60

70

80

90

100

110

Plot of tennis ball distance sample means

Charge size=2.5charge size=5

Propellant

Dist

ance

Tra

velle

d

From the plot,

• Propellant ordered by travelled distance are “Carburetor fluid is better than gasoline, which in turn is better than lighter fluid”

• “Charge size of 5 ml is better than charge size of 2.5 ml.”

• The distance pattern across propellant types is similar for charge size of 5ml and charge size of 2.5ml.

Fitted Effected

• We use the idea of fitted effects to quantify the qualitative summaries from the plot.

• For factorial data, the effects of factors are described as – Main effect – Interaction effect

The main effect of B = lighter fluid describes on average how much distance is gained or lost using lighter fluid compared to the overall average.

Overall mean = y = 78.53

Lighter fluid mean = 1y = 58.9 Effect of lighter fluid = 58.9 – 78.53 = -19.63 = b1

On average (over all charges) lighter fluid propelled balls 19.63 feet than the overall average distance. Effect of gasoline = 85.2 – 78.53 = 6.67 = b2

Effect of carb fluid = 91.5 – 78.53 = 12.97 = b3

Check: -19.63 + 6.67 + 12.97 = 0.01 = 0 except for round-off. Deviations from mean sum to zero.

The fitted main effect for factor B at level j is

bj = yy j

The fitted main effect for factor A at level i is

ai = yyi

Effect of charge 2.5 = 71.67 – 78.53 = -6.87 = a1

Effect of charge 5.0 = 85.4 – 78.53 = 6.87 = a2

Check: -6.87 + 6.87 = 0.

A = Propellant B = Charge LF Gasoline Carb F Mean 2.5 ml 71.67 a1 = 71.67 – 78.53 5.0 ml 85.40 a2 = 81.40 – 78.53

Mean 58.9 85.2 91.5 y =78.53

b1 = 58.9 – 78.53 b2 = 85.2 – 78.53 b3 = 91.5 – 78.53

Interaction effect

• Interactions check the extent to which main effects are consistent at different levels of the other factor.

– Are the propellant effects the same for each charge?

– Are the charge effects the same at each propellant?

020406080

100120

1 2 3

Propellant 1=lighter 2=gas 3=carb

Mea

n D

ista

nce

Charge 2.5

Charge 5.0

In this plot the effects of the propellants are similar for both charges. The increase in distance going from lighter to gas or gas to carburetor fluid is pretty similar for both charges. The lines are fairly parallel, particularly in view of variability in plot above. A situation with absolutely no interaction would have exactly parallel lines.

ijy

jiij bayy

The interaction between factor A and B is denoted AB or A*B.The corresponding effect sizes for interactions are abij, analogous to ai and bj.

abij measures the extent to which from a fit

with parallel lines.

To fit parallel lines, the fitted values depend only on main effects, no interaction terms.

For parallel profiles

Fitting parallel lines:Fitted value for a=1 and b=1, charge 2.5 and propellant lighter fluid

78.53 – 6.87 – 19.63 = 52.03

Compared to the overall average, we lose• 6.87 feet using charge 2.5• 19.63 feet using lighter fluid

11yThe deviation of =53.8 from the parallel lines, no interaction fit is

ab11 = 53.8 – 52.03 = 1.77

Using charge 1 and propellant 1 went 1.77 feet farther than expected than predicted with a no interaction model.

Interaction effects measure the extent to which a model with parallel lines, no interaction fits the observed means.

)( jiijij bayyab

Charge Lighter Gasoline Carburetor

2.5 ml 11y =53.8 12y =76.6 13y =84.6

5.0 ml 21y =64.0 22y =93.8 23y =98.4

y =78.53 Computing the abij effects:

Propellant Charge LF Gas C F 2.5 53.8 – (78.53 – 6.87 – 19.63) 76.6 – (78.53 – 6.87 + 6.67) etc a1 = – 6.87 5.0 64.0 – (78.53 + 6.87 – 19.63) 93.8 – (78.53 + 6.87 + 6.67 etc a2 = + 6.87 b1 = – 19.63 b2 = + 6.67 etc

For the propellant example a1 = -6.87 a2 = 6.87 b1 = -19.63 b2 = 6.67 b3 = 12.97 Charge Propellant PARALLEL

i j y ai bj FIT MEAN abij 1 1 78.53 -6.87 -19.63 52.03 53.8 1.77 1 2 78.53 -6.87 6.67 78.33 76.6 -1.73 1 3 78.53 -6.87 12.97 84.63 84.6 -0.03 2 1 78.53 6.87 -19.63 65.77 64 -1.77 2 2 78.53 6.87 6.67 92.07 93.8 1.73 2 3 78.53 6.87 12.97 98.37 98.4 0.03

11 11 1 1( )ab y y a b = 1.77

)( 211212 bayyab = -1.73

)( 311313 bayyab = -0.03

)( 122121 bayyab = -1.77

)( 222222 bayyab = 1.73

)( 322323 bayyab = 0.03

Interaction Effects

The fitted interactions in some sense measure how much pattern the combination means carry that is not explainable in terms of the factors A and B acting separately.

• Now, the overall mean, the fitted main effects, and the fitted interactions provide a decomposition or breakdown of the combination sample means into interpretable pieces.

• Those pieces correspond to an overall effect, the effects of factors acting separately, and the effects of factors acting jointly.

ij i j ijy y a b ab

The fitted value for each group is the mean for that treatment group

ijij yy ˆ

The model for the measured y value involves main effects and interactions

ijjiy

i true population effect of ith level of A

j true population effect of jth level of B

ij true population interaction effect

ij

jiijji

ijjiij

ijijjii

y

bayybay

abbay

abba

)(

ˆˆ

ˆ ˆ ˆ j

The residuals are

yye ˆ

ijijijijij yyyye ˆ

2R

222

2

22

2

ˆ( ) ( )

( )

( ) ( )

( )ij

y y y yR

y y

y y y y

y y

, as before, is the fraction reduction in sum of squared errors using the model fitted values compared to using a single mean to predict all y values

For example consider again the propellant example

Charge Propel y y eyy ˆ 2.5 Lighter 58 53.8 4.2 2.5 Lighter 50 53.8 -3.8 … 5.0 Carb 95 98.4 -3.4 5.0 Carb 97 98.4 -1.4

2 2 2 2 2

2 2 2 2 2 2

2

2

2

( ) (58 78.53) (58 78.53) ... (95 78.53) (97 78.53)

8041.47

ˆ( ) 4.2 ( 3.8) ... ( 3.4) ( 1.4)

585.2

8041.47 585.2

8041.47

7456.270.927

8041.47

92.7%

y y

e y y

R

R

R

The sum of squared (SS) errors account for or explained by the model is the numerator of R2 = 7456.27