Mann-Whitney U Test PDF

Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...

Summary

This document presents a question and solution for a Mann-Whitney U test. It involves analyzing the effects of two different diets on weight loss, using data from twenty participants. The test aims to determine if there's a significant difference in weight loss between the two diets. It also contains other statistical problems on cholesterol levels.

Full Transcript

Mann-Whitney U Test: Question and Solution 2 Question A researcher is studying the effects of two different diets on weight loss. Twenty partic- ipants are randomly assigned to either Diet A or Diet B, with ten participants in each group. After six weeks, the weight loss (in kilograms) of the part...

Mann-Whitney U Test: Question and Solution 2 Question A researcher is studying the effects of two different diets on weight loss. Twenty partic- ipants are randomly assigned to either Diet A or Diet B, with ten participants in each group. After six weeks, the weight loss (in kilograms) of the participants is recorded as follows: Diet A: 3.5, 4.2, 5.1, 3.8, 4.5, 5.0, 3.7, 4.8, 4.0, 5.3 Diet B: 2.8, 3.6, 4.0, 2.9, 3.2, 3.8, 3.1, 3.5, 2.7, 3.9 Use the Mann-Whitney U test to determine if there is a significant difference in weight loss between the two diets at a 5% significance level. State the null and alternative hypotheses. Calculate the test statistic. Interpret the result. 3 Solution Step 1: State the hypotheses The hypotheses for the Mann-Whitney U test are as follows: Null hypothesis (H0 ): There is no difference in the distribution of weight loss between Diet A and Diet B. Alternative hypothesis (H1 ): There is a difference in the distribution of weight loss between Diet A and Diet B. Step 2: Combine and rank the data We combine the data from both diets and assign ranks: Weight Loss (kg) Diet Rank 2.7 B 1 2.8 B 2 2.9 B 3 3.1 B 4 3.2 B 5 3.5 A 6.5 3.5 B 6.5 3.6 B 8 3.7 A 9 3.8 A 10.5 3.8 B 10.5 3.9 B 12 4.0 A 13.5 4.0 B 13.5 4.2 A 15 4.5 A 16 4.8 A 17 5.0 A 18 5.1 A 19 5.3 A 20 Step 3: Calculate the Mann-Whitney U statistic The Mann-Whitney U statistic is calculated using the formula: n1 (n1 + 1) U1 = n1 n2 + − R1 2 where: n1 = number of observations in Diet A = 10 n2 = number of observations in Diet B = 10 4 R1 = sum of ranks for Diet A = 151.5 Calculating U1 : 10 × (10 + 1) U1 = 10 × 10 + − 151.5 = 100 + 55 − 151.5 = 3.5 2 We also calculate U2 using the formula: U2 = n1 n2 − U1 = 10 × 10 − 3.5 = 96.5 The smaller of the two values, U = 3.5, is used for the test. Step 4: Determine the critical value and interpret the result Using a Mann-Whitney U critical value table for n1 = 10 and n2 = 10 at a 5% significance level, the critical value for a two-tailed test is 23. Since our calculated U = 3.5 is less than the critical value of 23, we reject the null hypothesis. Conclusion There is sufficient evidence to conclude that there is a statistically significant difference in the weight loss distributions between Diet A and Diet B. Question A nutritionist wants to determine if a new diet has a significant effect on cholesterol levels in individuals. Ten patients have their cholesterol levels measured before and after following the diet for 8 weeks. The cholesterol levels (in mg/dL) are as follows: Patient Before Diet After Diet 1 210 190 2 225 200 3 250 240 4 260 255 5 245 235 6 230 220 7 255 250 8 240 225 9 235 230 10 220 210 Use the Wilcoxon signed-rank test to determine if there is a statistically significant difference in cholesterol levels before and after the diet at a 5% significance level. State the null and alternative hypotheses. Calculate the test statistic. Interpret the result. 5 Solution Step 1: State the hypotheses The hypotheses for the Wilcoxon signed-rank test are as follows: Null hypothesis (H0 ): There is no difference in cholesterol levels before and after the diet. Alternative hypothesis (H1 ): There is a significant difference in cholesterol levels before and after the diet. Step 2: Calculate the differences and ranks Calculate the differences between the before and after measurements, their absolute val- ues, and then rank the absolute differences (ignoring the sign): Patient Before Diet After Diet Difference (D) Rank of |D| 1 210 190 20 3 2 225 200 25 5 3 250 240 10 1 4 260 255 5 2 5 245 235 10 1 6 230 220 10 1 7 255 250 5 2 8 240 225 15 4 9 235 230 5 2 10 220 210 10 1 Step 3: Assign signs to the ranks Assign the sign of the difference to each rank: Difference (D) Rank of |D| Signed Rank 20 3 +3 25 5 +5 10 1 +1 5 2 +2 10 1 +1 10 1 +1 5 2 +2 15 4 +4 5 2 +2 10 1 +1 Step 4: Calculate the test statistic Calculate the sum of the positive ranks (T+ ) and the sum of the negative ranks (T− ): T+ = 3 + 5 + 1 + 2 + 1 + 1 + 2 + 4 + 2 + 1 = 22 6 T− = 0 (since all differences were positive) The test statistic for the Wilcoxon signed-rank test is the smaller of T+ and T−. In this case, T = 0. Step 5: Determine the critical value and interpret the result For a sample size of n = 10 and a significance level of α = 0.05 (two-tailed test), the critical value from the Wilcoxon signed-rank table is 8. Since the calculated test statistic T = 0 is less than the critical value of 8, we reject the null hypothesis. Conclusion There is sufficient evidence to conclude that there is a statistically significant difference in cholesterol levels before and after the diet. Question A biologist is studying the relationship between plant species and the presence of a par- ticular insect species. The study involves 100 plants from two different species, observed to see whether they are infested with the insect. The data collected is as follows: Plant Species Insect Present Insect Absent Total Species A 25 15 40 Species B 35 25 60 Total 60 40 100 Use a Chi-squared test of association at a 5% significance level to determine if there is a significant association between the plant species and the presence of the insect. State the null and alternative hypotheses. Calculate the expected frequencies. Calculate the Chi-squared test statistic. Interpret the result. 7 Solution Step 1: State the hypotheses The hypotheses for the Chi-squared test of association are as follows: Null hypothesis (H0 ): There is no association between plant species and the presence of the insect. Alternative hypothesis (H1 ): There is an association between plant species and the presence of the insect. Step 2: Calculate the expected frequencies The expected frequency for each cell in the contingency table is calculated using the formula: (Row total) × (Column total) Expected frequency = Grand total Cell Observed Frequency (O) Expected Frequency (E) 40×60 Species A, Insect Present 25 100 = 24 40×40 Species A, Insect Absent 15 100 = 16 60×60 Species B, Insect Present 35 100 = 36 60×40 Species B, Insect Absent 25 100 = 24 Step 3: Calculate the Chi-squared test statistic The Chi-squared statistic is calculated using the formula: X (O − E)2 χ2 = E Calculating for each cell: (25 − 24)2 (15 − 16)2 (35 − 36)2 (25 − 24)2 χ2 = + + + 24 16 36 24 1 1 1 1 χ2 = + + + 24 16 36 24 2 χ = 0.0417 + 0.0625 + 0.0278 + 0.0417 = 0.1737 Step 4: Determine the critical value and interpret the result For a Chi-squared test with 1 degree of freedom (calculated as (number of rows − 1) × (number of columns − 1) = 1) and a significance level of 0.05, the critical value is 3.841. Since the calculated Chi-squared statistic (χ2 = 0.1737) is less than the critical value of 3.841, we fail to reject the null hypothesis. Conclusion There is not enough evidence to conclude that there is a significant association between plant species and the presence of the insect.

Use Quizgecko on...
Browser
Browser