Note Your answers to the questions below should follow the expectations for homework found here. Due date is on the Dates page.

## pH in Two Rivers

Burke Center researchers recorded the pH at ten locations in two streams that were close in proximity but in different watersheds that had markedly different geologies. They wanted to determine if the mean pH differed between the two streams. Their results are shown in the table below.

```Stream A: 8.97 9.12 9.41 8.67 9.94 8.28 7.86 7.51 9.18 7.68
Stream B: 6.67 5.83 6.84 6.86 5.89 7.42 6.56 5.99 5.33 6.69
```

Enter these data into R and construct tables of 2-Sample t-Test results (use `t.test()` and assume that the group variances are equal), ANOVA results (use `anova()` with an `lm()` object), and summary of coefficients (use `summary()` with an `lm()` object). [Note that you should have three appropriately labeled tables that you will refer to when answering the questions below.]

1. How do the p-values for the 2-Sample t-Test, the ANOVA table, and the slope (in the summary of coefficients table) compare? Explain why this relationship occurs. [Hint: You will need to discuss the H0 and HA for each p-value and explain how they are equivalent.]
2. What overall conclusion about the group means is made from these p-values?
3. How does the mean of the “first” group in the 2-Sample t-Test compare to either (but be specific about which one) of the coefficients from the linear model? Explain why this relationship occurs. [Hint: You will need to discuss how factors are coded in R and how an intercept is defined.]
4. How does the difference in means from the 2-Sample t-Test compare to either (again, be specific about which one) of the coefficients from the linear model. Explain why this relationship occurs [Hint: Again, you will need to discuss how factors are coded in R and how a slope is defined.]
5. How does the df from the 2-Sample t-Test compare to one of the df in the ANOVA table (again, be specific about which one). Explain why this relationship occurs. [Hint: You will need to discuss how these df are computed.]
6. How does the 2-Sample t-Test test statistic compare to the F test statistic in the ANOVA table. [Hint: The answer is in Section 1.8 of the reading. You can just state this as a fact without explanation.]
7. Use the formula for the t-test statistic (i.e., in Section 1.1 of the reading) and the results for the t-test test statistic from R to “back-calculate” a value for sp2. [Note that this algebraic manipulation needs to be done by hand. Leave space to show your work or show your work on an attached page.]
8. What value in the ANOVA table does your result for sp2 equal?