In: Statistics and Probability
Question 1:
Given the following probability distribution for a random variable
X: x P(X=x)
-2
0.30
-1
0.15
0
0.20
1
0.20
2
0.15
a) Explain two reasons why the above distribution is a valid
probability distribution.
b) Calculate μX and σX.
c) Determine the cdf(X), and write it as an additional column in
the table.
d) Calculate P(−1<X≤3) .
e) Draw a histogram that represents the probability distribution of
X.
Question 1 :
The probability distribution of X is
| x | -2 | -1 | 0 | 1 | 2 | Total |
| P(X=x) | 0.30 | 0.15 | 0.20 | 0.15 | 0.15 | 1 |
a) i) Since
for
every value of X
ii) Total of all probabilities is 1.
Hence given probability distribution is valid.
b)
| x | p | x*p | x2*p |
| -2 | 0.3 | -0.6 | 1.2 |
| -1 | 0.15 | -0.15 | 0.15 |
| 0 | 0.2 | 0 | 0 |
| 1 | 0.2 | 0.2 | 0.2 |
| 2 | 0.15 | 0.3 | 0.6 |
| Total | 1 | -0.25 | 2.15 |
The expected value of X is given by


Variance of X is given by



Standard deviation of X is

c) Cumulative distribution function of X is

| x | p | F(x) |
| -2 | 0.3 | 0.3 |
| -1 | 0.15 | 0.45 |
| 0 | 0.2 | 0.65 |
| 1 | 0.2 | 0.85 |
| 2 | 0.15 | 1 |
d)
= 0.2 + 0.2 +0.15
= 0.55
e) For drawing histogram
Consider total frequency = 100
By using R
> x=seq(-2,2,1)
> y=c(30,15,20,20,15)
> f=rep(x,y)
> hist(f)
> t=seq(-2.5,2.5,1)
> hist(f,breaks=t,main="Histogram")
