3.1 An experimenter has conducted a single-factor experiment with four levels of the factor, and each factor level has been replicated sixtimes. The computed value of the F-statistic is \(F_o\) = 3.26. Find bounds on the P-value.
pf(3.26, 3, 20, lower.tail=FALSE)
## [1] 0.04300116
3.2 An experimenter has conducted a single-factor experiment with six levels of the factor, and each factor level has been replicated three times.The computed value of the F-statistic is \(F_o\) = 5.81. Find bounds on the P-value.
pf(5.81, 5, 9, lower.tail=FALSE)
## [1] 0.01141666
3.3 An experimenter has conducted a single-factor completely randomized design with five levels of the factor and three replicates. The computed value of the F-statistic is 4.87. Find bounds on the P-value.
pf(4.87, 4, 10, lower.tail=FALSE)
## [1] 0.01932984
3.5 The mean square for error in the ANOVA provides an estimate of
(a) The variance of the random error
(b) The variance of an individual treatment average
(c) The standard deviation of an individual observation
(d) None of the above
3.7 A computer ANOVA output is shown below. Fill in the blanks. You may give bounds on the P-value.
\(\hspace{200pt}\) One-way ANOVA
| Source | DF | SS | MS | F | p |
|---|---|---|---|---|---|
| Factor | 3 | 36.15 | 12.05 | 1.13 | 0.37 |
| Error | 15 | 159.89 | 10.66 | ||
| Total | 19 | 196.04 |
Error DF -> N-a = 19-4 = 15
SS Error -> SS Total-SS Factor = 196.04-36.15 = 159.89
MS Factor -> SS Factor/DF Factor = 36.15/3
MS Error -> SS Error/DF Error = 159.89/15
F -> MS Factor/MS Error = 12.05/10.66
P-value:
pf(1.13, 3, 15, lower.tail=FALSE)
## [1] 0.3685193
3.8 A computer ANOVA output is shown below. Fill in the blanks. You may give bounds on the P-value.
\(\hspace{200pt}\) One-way ANOVA
| Source | DF | SS | MS | F | p |
|---|---|---|---|---|---|
| Factor | 3 | 987.71 | 246.93 | 33.1 | 7.281125e-09 |
| Error | 25 | 186.53 | 7.4612 | ||
| Total | 29 | 1174.24 |
DF Factor -> a-1 or Total-Error DF = 29-25 = 4 SS Factor -> SS Total-SS Error = 1174.24-186.53 = 987.71
MS Error -> SS Error/DF Error = 186.53/25 = 7.4612
F -> MS Factor/MS Error = 246.93/7.46125 = 33.09499
P-value:
pf(33.1, 3, 25, lower.tail=FALSE)
## [1] 7.281125e-09
3.9
Is this study really a designed experiment? Does it establish a cause-and-effect link between chocolate consumption and depression? How would the study have to be conducted to establish such a cause-and-effect link?
\(\hspace{20pt}\) Since they don’t really control anything, this is an obsevational study. They don’t control the chocolate consumption, the subjects, or their depression.
\(\hspace{20pt}\) I don’t think it establishes cause-and-effect because it seems like happenstance. It could be just that eating sweets in general is linked to depression or it might actually be chocolate but we can’t tell from the study even though they mention that they examined other foods.
\(\hspace{20pt}\) We would have to see what chocolate does to people in depression or just people in general. Like check/test for chemical reactions, dopamine levels and the like. Then also see if the same thing happens in other foods or sweets too.
3.10
Step 1:
Does common pulsing electromagnetic field (PEMF) treatment moderate the substantial osteopenia that occurs after forearm disuse?
Step 2:
Factor of interest is PEMF treatment. And we have 4 levels of it, Sham, PEMF1h/day, PEMF2h/day, and PEMF4h/day. This is the variable that we control. and the 4 levels tell us that it’s categorical.
Step 3:
Response variable is the percentage of Bone mineral density(BMD) after the treatments. The BMD will be measured by dual energy X-ray absorptiometry (DXA) and peripheral quantitative computedtomography(pQCT). The measurements where measured after 16 weeks of wearing the active of sham PEMF treatments.
Step 4:
T, Z or ANOVA? Since we have 4 levels of the factor, we use ANOVA.
Step 5:
Data set:
dat3.10 <- data.frame(
Sham = c(4.51,7.95,4.97,3.00,7.97,2.23,3.95,5.64,9.35,6.52,4.96,6.10,7.19,4.03,2.72,9.19,5.17,5.70,5.85,6.45),
PEMF1h_day =c(5.32,6.00,5.12,7.08,5.48,6.52,4.09,6.28,7.77,5.68,8.47,4.58,4.11,5.72,5.91,6.89,6.99,4.98,9.94,6.38),
PEMF2h_day = c( 4.73 ,5.81 , 5.69 , 3.86 , 4.06 , 6.56, 8.34, 3.01 , 6.71 ,6.51 , 1.70, 5.89 , 6.55 , 5.34 , 5.88 , 7.50 , 3.28 , 5.38 , 7.30 ,5.46),
PEMF4h_day = c(7.03, 4.65 ,6.65,5.49 ,6.98,4.85,7.26,5.92 ,5.58 ,7.91,4.90,4.54 ,8.18 ,5.42 ,6.03 ,7.04 ,5.17 ,7.60 ,7.90, 7.91),
stringsAsFactors = FALSE
)
dat3.10 <- stack(dat3.10) # because the dataframe above seperated the factors by columns
dat3.10
## values ind
## 1 4.51 Sham
## 2 7.95 Sham
## 3 4.97 Sham
## 4 3.00 Sham
## 5 7.97 Sham
## 6 2.23 Sham
## 7 3.95 Sham
## 8 5.64 Sham
## 9 9.35 Sham
## 10 6.52 Sham
## 11 4.96 Sham
## 12 6.10 Sham
## 13 7.19 Sham
## 14 4.03 Sham
## 15 2.72 Sham
## 16 9.19 Sham
## 17 5.17 Sham
## 18 5.70 Sham
## 19 5.85 Sham
## 20 6.45 Sham
## 21 5.32 PEMF1h_day
## 22 6.00 PEMF1h_day
## 23 5.12 PEMF1h_day
## 24 7.08 PEMF1h_day
## 25 5.48 PEMF1h_day
## 26 6.52 PEMF1h_day
## 27 4.09 PEMF1h_day
## 28 6.28 PEMF1h_day
## 29 7.77 PEMF1h_day
## 30 5.68 PEMF1h_day
## 31 8.47 PEMF1h_day
## 32 4.58 PEMF1h_day
## 33 4.11 PEMF1h_day
## 34 5.72 PEMF1h_day
## 35 5.91 PEMF1h_day
## 36 6.89 PEMF1h_day
## 37 6.99 PEMF1h_day
## 38 4.98 PEMF1h_day
## 39 9.94 PEMF1h_day
## 40 6.38 PEMF1h_day
## 41 4.73 PEMF2h_day
## 42 5.81 PEMF2h_day
## 43 5.69 PEMF2h_day
## 44 3.86 PEMF2h_day
## 45 4.06 PEMF2h_day
## 46 6.56 PEMF2h_day
## 47 8.34 PEMF2h_day
## 48 3.01 PEMF2h_day
## 49 6.71 PEMF2h_day
## 50 6.51 PEMF2h_day
## 51 1.70 PEMF2h_day
## 52 5.89 PEMF2h_day
## 53 6.55 PEMF2h_day
## 54 5.34 PEMF2h_day
## 55 5.88 PEMF2h_day
## 56 7.50 PEMF2h_day
## 57 3.28 PEMF2h_day
## 58 5.38 PEMF2h_day
## 59 7.30 PEMF2h_day
## 60 5.46 PEMF2h_day
## 61 7.03 PEMF4h_day
## 62 4.65 PEMF4h_day
## 63 6.65 PEMF4h_day
## 64 5.49 PEMF4h_day
## 65 6.98 PEMF4h_day
## 66 4.85 PEMF4h_day
## 67 7.26 PEMF4h_day
## 68 5.92 PEMF4h_day
## 69 5.58 PEMF4h_day
## 70 7.91 PEMF4h_day
## 71 4.90 PEMF4h_day
## 72 4.54 PEMF4h_day
## 73 8.18 PEMF4h_day
## 74 5.42 PEMF4h_day
## 75 6.03 PEMF4h_day
## 76 7.04 PEMF4h_day
## 77 5.17 PEMF4h_day
## 78 7.60 PEMF4h_day
## 79 7.90 PEMF4h_day
## 80 7.91 PEMF4h_day
ANOVA:
summary(aov(values~as.factor(ind), dat3.10))
## Df Sum Sq Mean Sq F value Pr(>F)
## as.factor(ind) 3 10.04 3.348 1.298 0.281
## Residuals 76 196.03 2.579
Since we have a p-value of 0.281, we can’t reject the claim the PEMF usage affects BMD loss.
3.11
Step 1:
Do the four different mixing techniques affect the tensile strength of Portland cement?
Step 2:
Factor of interest is the mixing technique. There are four different mixing techniques. So the factor has 4 levels and is categorical.
Step 3:
Response variable is the tensile strength. This variable will be measured by the pound per squared inc, \(lb/in^2\).
Step 4:
T, Z or ANOVA? Since we have 4 levels of the factor, we use ANOVA.
Step 5:
Data set:
dat3.11 <- data.frame(
"1" = c(3129, 3000, 2865, 2890),
"2" = c(3200, 3300, 2975, 3150),
"3" = c(2800, 2900, 2985, 3050),
"4" = c(2600, 2700, 2600, 2765),
stringsAsFactors = FALSE
)
dat3.11 <- stack(dat3.11)
dat3.11
## values ind
## 1 3129 X1
## 2 3000 X1
## 3 2865 X1
## 4 2890 X1
## 5 3200 X2
## 6 3300 X2
## 7 2975 X2
## 8 3150 X2
## 9 2800 X3
## 10 2900 X3
## 11 2985 X3
## 12 3050 X3
## 13 2600 X4
## 14 2700 X4
## 15 2600 X4
## 16 2765 X4
ANOVA:
summary(aov(values~as.factor(ind), dat3.11))
## Df Sum Sq Mean Sq F value Pr(>F)
## as.factor(ind) 3 489740 163247 12.73 0.000489 ***
## Residuals 12 153908 12826
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
We can reject the claim that the mixing techniques affect the strength of the cement because, after conducting the experiment we get a p-value of .000489.
3.16
Step 1:
Does the dosage of a new drug affect bioactivity?
Step 2:
Factor of interest is the dosage. We control the amount of grams that we give to the subject to measure the subjects bioactivity. We chose 20g, 30g, and 40g as our three levels of the factor.
Step 3:
Response variable is the level of bioactivity. Observations were measured after the subject took the dosage given to them.
Step 4:
T, Z or ANOVA? Since we have 3 levels of the factor, we use ANOVA.
Step 5:
Data set:
dat3.16 <- data.frame(
"20g" = c(24, 28, 37, 30),
"30g" = c(37, 44, 31, 35),
"40g" = c(42, 47, 52, 38),
stringsAsFactors = FALSE
)
dat3.16 <- stack(dat3.16)
dat3.16
## values ind
## 1 24 X20g
## 2 28 X20g
## 3 37 X20g
## 4 30 X20g
## 5 37 X30g
## 6 44 X30g
## 7 31 X30g
## 8 35 X30g
## 9 42 X40g
## 10 47 X40g
## 11 52 X40g
## 12 38 X40g
ANOVA:
summary(aov(values~as.factor(ind), dat3.16))
## Df Sum Sq Mean Sq F value Pr(>F)
## as.factor(ind) 2 450.7 225.33 7.036 0.0145 *
## Residuals 9 288.2 32.03
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
With a p-value of .0145, we can reject the claim that the dosage level affects bioactivity.
3.17
Step 1:
Does the type of car rented affect the length of the rental period?
Step 2:
Factor of interest is car type. We can control what type of car people choose by having the type available versus not having it in stock. We 4 diffent types Subcompact, Compact, Midsize, and Fullsize.
Step 3:
Response variable is the rental period. This is the variable that we take and measure from the rental contract.
Step 4:
T, Z or ANOVA? Since we have 4 levels of factor, we use ANOVA.
Step 5:
Data set:
## values ind
## 1 3 Subcompact
## 2 5 Subcompact
## 3 3 Subcompact
## 4 7 Subcompact
## 5 6 Subcompact
## 6 5 Subcompact
## 7 3 Subcompact
## 8 2 Subcompact
## 9 1 Subcompact
## 10 6 Subcompact
## 11 1 Compact
## 12 3 Compact
## 13 4 Compact
## 14 7 Compact
## 15 5 Compact
## 16 6 Compact
## 17 3 Compact
## 18 2 Compact
## 19 1 Compact
## 20 7 Compact
## 21 4 Midsize
## 22 1 Midsize
## 23 3 Midsize
## 24 5 Midsize
## 25 7 Midsize
## 26 1 Midsize
## 27 2 Midsize
## 28 4 Midsize
## 29 2 Midsize
## 30 7 Midsize
## 31 3 Fullsize
## 32 5 Fullsize
## 33 7 Fullsize
## 34 5 Fullsize
## 35 10 Fullsize
## 36 3 Fullsize
## 37 4 Fullsize
## 38 7 Fullsize
## 39 2 Fullsize
## 40 7 Fullsize
ANOVA:
summary(aov(values~as.factor(ind), dat3.17))
## Df Sum Sq Mean Sq F value Pr(>F)
## as.factor(ind) 3 16.67 5.558 1.11 0.358
## Residuals 36 180.30 5.008
Experiment resulted in a p-value of 0.358, which means we can’t reject the claim that the type of car rented affects the length of the rental period