Solution for midterm 2
1. Consider the following random sample: 0.3, 0.7, 1.4, 0.9, 2.5, 3.0, 2.1, 2.4, 2.8, 0.5,
1.1, 2.6. Use the goodnessofﬁt test to check whether it is reasonable to believe, at the
signiﬁcance level of 0.05, that this sample is from a uniform distribution on [0
,a
] where
a
is
an unknown parameter.
Hint
: use max
i
X
i
as the estimator for
a
.
Solution:
We estimate the parameter
a
as ˆ
a
= 3
.
0.
Since
n
= 12 we can use as many as 4 bins. Since the hypothesized distribution is
uniform, the bins should be the same size. That makes them [0
,
0
.
75], [0
.
75
,
1
.
5], [1
.
5
,
2
.
25]
and [2
.
25
,
3
.
0], respectively. So the observed frequencies are
O
1
= 3,
O
2
= 3,
O
3
= 1,
O
4
= 5.
All expected frequencies are equal to 12
/
4 = 3. So, the test statistic is
χ
2
0
=
1
3
(0 + 0 + 4 + 4) = 2
.
67
,
and since
χ
2
0
< χ
2
0
.
05
,
4

1

1
=
χ
2
0
.
05
,
2
= 5
.
99, we conclude that the null hypothesis cannot be
rejected, and it is reasonable to believe that the sample came from a uniform distribution.
2. The probability theorist has constructed a simple regression model for the price of