Question

In: Statistics and Probability

Given contingency table for simultaneous occurance of two categorical random variables X (levels A,B,C) and Y...

Given contingency table for simultaneous occurance of two categorical random variables X (levels A,B,C) and Y (levels L1,L2,L3)

L1 L2 L3
A 10 20 30
B 15 20 30
C 25 22 32

Determine the marginal probability P ( X = B ) =  (round to the sthird decimal place)

Determine the conditional probability P ( Y = L 2 | X = B ) =  (round to the second decimal place)

Use R to conduct a chi-square test of independence and thus determine

  • Number of degrees of freedom DF=
  • Ch-square, round to two decimal places=
  • p-value, round to two decimal places=
  • Make your conclusion at 5% significance. Enter the correct answer using the following options:  (type the corresponding capital letter, do not type the "dot" at the end)
    1. Not independent at 5% significance level.
    2. Independent with 95% confidence.
    3. Do not reject that they are independent at 5% significance level and reserve judgement. We may accept independence, but with some unknown probability.
    4. Reject both, H0 and H1, the test has failed.
    5. Accept both, H0 and H1, the test has failed.

Solutions

Expert Solution

Observed L1 L2 L3 Total
A 10 20 30 60
B 15 20 30 65
C 25 22 32 79
total 50 62 92 204

from above

1) P(X=B)=65/204=0.32

2)P(Y=L2 |X=B) =20/65 =0.31

3)

degree of freedom(df) =(rows-1)*(columns-1)= 4

4)

Applying chi square test of independence:
Expected Ei=row total*column total/grand total L1 L2 L3 Total
A 14.706 18.235 27.059 60
B 15.931 19.755 29.314 65
C 19.363 24.010 35.627 79
total 50 62 92 204
chi square    χ2 =(Oi-Ei)2/Ei L1 L2 L3 Total
A 1.506 0.171 0.320 1.9964
B 0.054 0.003 0.016 0.0736
C 1.641 0.168 0.369 2.1788
total 3.2016 0.3421 0.7051 4.2487
test statistic X2= 4.249

5)

p value = 0.373

6)

Do not reject that they are independent at 5% significance level and reserve judgement. We may accept independence, but with some unknown probability.


Related Solutions

Q1: A sample with two variables (x and y) is given in the table. According to...
Q1: A sample with two variables (x and y) is given in the table. According to the sample, please develop an excel spreadsheet to calculate the missing values given in the table of “summary output” attached below. The excel spreadsheet needs to be submitted together with your assignment. Note: use “data analysis toolpak” to check your answers, but calculations, equations and steps should be done for each "?" value x y 1.0 5.2 1.5 7.2 2.0 5.5 2.5 4.9 3.0...
The joint probability density function for two random variables X and Y is given as, fx,y...
The joint probability density function for two random variables X and Y is given as, fx,y (x, y) = (2/3)(1 + 2xy3 ), 0 < x < 1, 0 < y < 1 (a) Find the marginal probability density functions for X and Y . (b) Are X and Y independent? Justify your answer. (c) Show that E[X] = 4/9 and E[Y ] = 7/15 . (d) Calculate Cov(X, Y )
Given two random variables x and y State of Nature   Probability   variable x   variable y I...
Given two random variables x and y State of Nature   Probability   variable x   variable y I 0.2 18 0 II 0. 2 5 -3 III 0.2 12 15 IV 0.2 4 12 V 0.2 6 1 (i) Calculate the mean and variance of each of these variables and the covariance between them (ii) Suppose x and y represent the returns from two assets. Calculate the mean and variance for the following part folios. % in x 125 100 75 50...
In this problem there are two random variables X and Y. The random variable Y counts...
In this problem there are two random variables X and Y. The random variable Y counts how many times we roll the die in the following experiment: First, we flip a fair coin. If it comes Heads we set X= 1 and roll a fair die until we get a six. If it comes Tails, we set X= 0 and roll the die until we get an even number (2, 4 or 6). a). What are the possible values taken...
Given below is a bivariate distribution for the random variables x and y. f(x, y) x...
Given below is a bivariate distribution for the random variables x and y. f(x, y) x y 0.3 50 80 0.2 30 50 0.5 40 60 (a) Compute the expected value and the variance for x and y. E(x) = E(y) = Var(x) = Var(y) = (b) Develop a probability distribution for x + y. x + y f(x + y) 130 80 100 (c) Using the result of part (b), compute E(x + y) and Var(x + y). E(x...
Let X and Y be two independent random variables such that X + Y has the...
Let X and Y be two independent random variables such that X + Y has the same density as X. What is Y?
Suppose the joint probability distribution of two binary random variables X and Y are given as...
Suppose the joint probability distribution of two binary random variables X and Y are given as follows. x/y 1 2 0 3/10 0 1 4/10 3/10 X goes along side as 0 and 1, Y goes along top as 1 and 2 e) Find joint entropy H(X, Y ). f) Suppose X and Y are independent. Show that H(X|Y ) = H(X). g) Suppose X and Y are independent. Show that H(X, Y ) = H(X) + H(Y ). h)...
The joint probability density function (PDF) of two random variables (X,Y) is given by ???(?,?) =...
The joint probability density function (PDF) of two random variables (X,Y) is given by ???(?,?) = { 1, 0 ≤ ? ≤ 2,0 ≤ ? ≤ 1,2? ≤ ? 0, otherwise 1) Find the correlation coefficient ??? between the two random variables X and Y Find the probability P(Y>X/2). help please asap
for the quantitative variables x and y are given in the table below. These data are...
for the quantitative variables x and y are given in the table below. These data are plotted in the scatter plot shown next to the table. In the scatter plot, sketch an approximation of the least-squares regression line for the data. x y 7.4 6.6 4.0 5.0 2.0 3.9 3.1 5.0 9.4 8.4 4.7 5.9 6.6 6.2 8.5 6.9 7.9 7.3 1.6 3.7 4.4 4.6 2.8 3.9 2.7 3.1 5.7 6.3 5.9 7.3 9.7 8.3 6.9 6.3 8.8 8.4 x...
.The following table displays the joint probability distribution of two discrete random variables X and Y....
.The following table displays the joint probability distribution of two discrete random variables X and Y. -1 0 1 2 1 0.2 0 0.16 0.12 0 0.3 0.12 0.1 0 What is P(X=1/Y=1)?    What is the value of E(X/Y=1)?    What is the value of VAR(X/Y = 1)? What is the correlation between X and Y? What is variance of W = 4X - 2Y. What is covariance between X and W?
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT