Skip to main content
The table needs to be inputed into R in order to answer the following questions. Thank you



ANSWER

We can easily calculate the expected cell counts Eij using the Minitab command chisq, as shown below.
MTB > read c1-c4
DATA> 12 8 31 41
DATA> 307 246 439 245
DATA> end
2 rows read.
MTB > chisq c1-c4
Expected counts are as below observed counts
C1     C2     C3     C4     Total
1       12    8      31    41        92
22.08   17.58     32.54    19.80
2      307 246 439   245 1237
296.92 236.42 437.46 266.20
Total          319   254 470 286 1329
ChiSq = 4.604 + 5.223 + 0.072 + 22.704 + 0.342 + 0.388 + 0.005 + 1.689 = 35.028
df = 3
MTB > cdf 35.028;
SUBC> chisq 3.
35.0280 1.0000
The p-value is essentially zero, so the evidence of a relationship is very strong. The same computation is shown below in S-PLUS, using the function chisq.test().
> x_c(12,8,31,41,307,246,439,245)
> x_matrix(x,4,2,byrow=T)
> chisq.test(x)
Pearson’s chi-square test without Yates’ continuity correction
data: x
X-squared = 35.0285, df = 3, p-value = 0
Through the X2 test for independence, we have demonstrated beyond a reasonable doubt that a relationship exists between cholesterol and CHD.
It would make sense to estimate the conditional probabilities of CHD within the four cholesterol groups. To do this, we estimate P(Y = i|Z = j).
P(Y = i|Z = j) = P(Y = i, Z = j) / P(Z = j)
[(nij/n++) / (n+j/n++)] = nij / n+j
12/319 = .038
8/254 = .031
31/470 = .066
41/286 = .143
307/319 = .962
246/254 = .969
439/470 = .934
245/286 = .857
The risk of CHD appears to be essentially constant for the 0–199 and 200–219 groups.
a test of independence for the 2 × 2 table
12
8
307
246
yields X 2 = 0.157, p-value = .69.
For an I × J table, the usual X 2 or G 2 test for independence has
(IJ − 1) − (I − 1) − (J − 1) = (I − 1)(J − 1)

Comments

  1. https://www.chegg.com/homework-help/questions-and-answers/2-survey-find-main-causes-lateness-factory-s-work-force-random-sample-200-employees-late-w-q38226745

    ReplyDelete

Post a Comment

Popular posts from this blog

Osmosis Data Sheet

Data Sheet: Activity - Osmosis Name Course Date Activity Data Code       Procedure I -Test Solution 1: Water Complete the tablesand questions below using your data and information found under the Background tab Data Table I Note: Difference in Final Volumes = Final Volume of Test Sol - Final Volume of Water Trial Starting Volume of Test Solution (L) Starting Volume of Water (L) Final Volume of Test Solution (L) Final Volume of Water (L) Difference in Final Volumes (L) 1 1.28 1.75 1.51 1.52 -0.01 2 1.28 2.00 1.64 1.64 0 Observations and Questions [1] Given that the final heights (and volumes) are the same for the water and test solution, what can you...
Simple Computer Science Questions Question 2 ANSWER Match the following a - 4 b - 10 c - 8 d - 6 e - 9 f - 1 g - 2 h - 7 i - 3 j - 5
Question: 7. A circular cam 200 mm in diameter rotates off centre with an eccentricity of 25 mm and operates the roller follower that is carried by the arm as shown in Fig. 23.35. ???200 mm +100mm- Spring 25 mm Fig. 23.35 The roller follower is held against the cam by means of an extension spring. Assuming that the force between the follower and the cam is approximately 250 N at the low position and 400 N at the high position. If the spring index is 7, find the diameter of wire, outside diameter of spring and the number of active coils. The maximum shear stress may be taken as 280 MPa. Use G 80 kN/mm2 ANSWER