## Statistical computing with SAS

1. A continuous RV X has a pdf of the form f(x) = 2x/9 for 0 < x < 3 and

zero otherwise (BE 2.18):

(a) Find the CDF of X.

(b) Find P(X ≤ 2).

(c) Find P(−1 < X < 1.5)

(d) Find a number m such that P(X ≤ m) = P(X ≥ m)

(e) Find E[X].

Solution : (a) F(x) = ( 1 , x ≥ 3

x

2/9 , 0 < x < 3

0 , x ≤ 0

(b) 4/9, (c) 1/4, (d) 3√

2/2, (e) 2, (f) 1/2

2. Suppose that X1 and X2 are discrete random variables with joint pdf of

the form

f(x1, x2) = c(x1 + x2) x1 = 0, 1, 2; x2 = 0, 1, 2

and zero otherwise. Find the constant c. [BE4.Q7]

Solution : 1/18

3. Let X and Y be continuous random variables with a joint pdf of the form

f(x, y) = f(x, y) = k(x + y) , 0 ≤ x, y ≤ 1

and zero otherwise. [BE4.Q19]

(a) Find k so that f(x, y) is a joint pdf.

(b) Find the marginal f(x) and f(y).

(c) Find the conditional pdf f(y|x).

(d) Find the conditional pdf f(x|y).

Solution :

(a) k = 1

(b) fX = 1/2 + x

fY = 1/2 + y

(c) f(y|x) = x + y

1/2 + x

(d) f(x|y) = x + y

1/2 + y

4. Suppose X and Y are continuous random variables with joint pdf f(x, y) =

4(x − yx) if 0 < x, y < 1 and zero otherwise. [BE4.Q28]

(a) Are X and Y independent? Why or why not?

1

(b) Find P(X ≤ Y ).

Solution :

(a) Yes. Because f(x, y) = f(x)f(y) for 0 < x < 1 and 0 < y < 1.

(b) 1/6

5. A softball team has three pitchers, A, B, and C with winning percentages

of 0.4, 0.6 and 0.8 respectively. These pitchers pitch with frequency 2, 3,

and 5 out of every 10 games, respectively. In other words, for a randomly

selected game, P(A) = 0.2, P(B) = 0.3 and P(C) = 0.5. (BE 1.32)

(a) P(team wins game) = P(W).

(b) P(A pitched game|team won) = P(A|W).

Solution : (a) 0.66, (b) 0.1212

6. A 2 × 1 vector X has mean zero and covariancce Σ =

1 0

0 2

. Let Y =

X1 + X2 = AX. Find a linear transformation matrix C then E[Y ] and

Var(Y ).

Solution : C = [1, 1] and E[Y ] = 0 and Var(Y ) = 3

7. Try the question 6 when Σ =

1 −0.3

−0.3 2

.

Solution : E[Y ] = 0 and Var(Y ) = 2.4

8. Suppose that (x1, . . . , xd) are d-indepdent samples from a Binomial distribution

Binom(N, p). Show that H =

1

d

Pd

i=1 xi/N is an unbiased

esitimator for p.

Solution :

E[H] = 1

d

X

d

i=1

E[xi

]

N

= p

2