Next: Recitation 14
Up: Recitation Sections
Previous: Recitation 12
Comparing Two Populations or Treatments
- 1.
- An experiment for comparing the protein content in Sundance
winter wheat and Manitou spring wheat used nine plots. Each plot
was planted with the Suncance wheat and then the Manitou wheat.
The results are given in the following table. Protein content is
measured in grams per kilogram of wheat.
| |
Location |
| |
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
| Sundance |
77 |
84 |
116 |
145 |
100 |
154 |
114 |
149 |
137 |
| Manitou |
125 |
111 |
144 |
171 |
133 |
166 |
143 |
175 |
170 |
| Difference |
48 |
27 |
28 |
26 |
33 |
12 |
29 |
26 |
33 |
The sample mean difference is 29.11 and the sample standard
deviation of the differences is 9.387.
- (a)
- Is there evidence that the mean protein levels for the two
wheat varieties are different?
- (b)
- Give a 90% confidence interval for the difference in the
population mean protein concentrations for the two varieties of
wheat.
- 2.
- A researcher studies a sample of 60 male soccer players to
examine the relation between IQ and frequency of ``heading'' the
ball. The soccer players were divided into two groups, based on
whether or not they averaged 10 or more headers per game. The
sample sizes, sample average IQs, and sample standard deviation
of the IQs are
| |
|
Sample |
Sample |
| |
n |
mean IQ |
sd of IQs |
| Fewer than 10 headers |
35 |
112 |
10 |
| 10 or more headers |
25 |
103 |
8 |
- (a)
- Is there evidence that the average IQ of male soccer players
who head the ball 10 or fewer times is lower than for players
who head the ball more often?
- (b)
- Find a 95% confidence interval for the difference of the
average IQs of male soccer players who head the ball 10 or
fewer times and those who head the ball more often.
- (c)
- A report on this research claimed that it had shown that
frequently heading the ball in soccer lowers players' IQs.
Comment on this claim.
Comparing Two Populations or Treatments Using Rweb
Go to
http://www.superior.stat.umn.edu/Rweb
on your web browser. Click on the first option for Rweb under
``Which Version Do You Want?''.
Type the following in the box to enter the data into Rweb and
calculate the mean and standard deviation of the dfferences within
plots.
sundance <- c(77,84,116,145,100,154,114,149,137)
manitou <- c(125,111,144,171,133,166,143,175,170)
mean(sundance-manitou)
sd(sundance-manitou)
Then press the Submit button. The resulting output should
tell you that the mean difference is -29.11111 and the standard
deviation of the differences is 9.386752. If you do not get these
answers use the Back option on your browser and check that
you have entered the data in correctly. If you have not then edit
your data and click Submit again.
When your data is correct add the line
t.test(sundance,manitou,paired=T)
to the bottom of your other commands. This will give a 95%
confidence interval and a p-value for the paired t-test for this
data. The p-value should be
and the
confidence interval -36.3 to -21.9.
Rweb used the default settings of a two-sided alternative and a 95%
confidence interval. The same answer is given by:
t.test(sundance,manitou,paired=T,alternative="two.sided",mu=0,paired=T,conf.level=0.95)
Type
help("t.test")
to see other options. Try them. Also try
stem(sundance-manitou)
boxplot(sundance-manitou)
to plot the data and examine whether the normal assumption is
appropriate. Is it?
You can use the function pt to calculate t-probabilities.
For example
pt(-9.3039,8)
gives the probability that a T random variable with 8 degrees of
freedom is less than -9.3039. The answer is
and the p-value for the two-sided test above is twice this
or
2*pt(-9.3039,8)
If you omit the paired=T in the t.test line and
just type
t.test(sundance,manitou)
you will get a two sample test for this data set - which is not
appropriate for this data.
You can use Rweb to check your calculations, do your homework, and
calculate p-values more precisely than from Table C. (But as Rweb
will not be available for the final and you will only have Table C,
please make sure you know how to use Table C also!)
You can also try going to
http://www.stat.umn.edu/CLASSES/faculty/luke/classes/3011/rwebnotes
and examine the examples given there.
Next: Recitation 14
Up: Recitation Sections
Previous: Recitation 12
Luke Tierney
2000-05-15