Comparing I 2 Groups Numeric Responses Extension of Methods used to Compare 2 Groups Independent and Dependent Samples Normal and non normal data structures Data Design Independent Samples CRD Normal Non normal F Test 1 Way ANOVA Kruskal Wallis Test Dependent Samples RBD F Test 2 Way ANOVA Friedman s Test Independent Samples Completely Randomized Design CRD Controlled Experiments Subjects assigned at random to one of the I treatments to be compared Observational Studies Subjects are sampled from I existing groups Statistical model xij is a subject from group i xij i ij where is the population mean of group treatment i ij is a random error 1 Way ANOVA for Normal Data CRD For each group obtain the mean standard deviation and sample size xi xij j ni si 2 x x i ij j ni 1 Obtain the overall mean and sample size N n1 nI n1 x1 nI x I i j xij x N N Analysis of Variance Sums of Squares Degrees of Freedom Total Variation I ni SST i 1 j 1 xij x 2 DFT N 1 Among Group Variation I ni I SSG i 1 j 1 x i x i 1 ni x i x 2 2 DFG I 1 Within Group Variation I n I SSE i 1 ji 1 xij x i 2 i 1 ni 1 si2 SST SSG SSE DFT DFG DFE DFE N I Analysis of Variance Table and F Test Source of Variation Treatments Error Total Sum of Squares SSG SSE SST Degrres of Freedom I 1 N I N 1 Mean Square MSG SSG I 1 MSE SSE N I F F MSG MSE H0 No differences among Group Means I HA Group means are not all equal Not all i are equal MSG T S Fobs MSE R R Fobs F I 1 N I P value P F Fobs Table E Example Relaxation Music in PatientControlled Sedation in Colonoscopy Three Conditions Treatments Music and Self sedation i 1 Self Sedation Only i 2 Music alone i 3 Outcomes Patient satisfaction score all 3 conditions Amount of self controlled dose conditions 1 and 2 Source Lee et al 2002 Example Relaxation Music in PatientControlled Sedation in Colonoscopy Summary Statistics and Sums of Squares Calculations Trt i 1 2 3 Total ni 55 55 55 165 Mean 7 8 6 8 7 4 overall mean 7 33 Std Dev 2 1 2 3 2 3 SSG 55 7 8 7 33 2 55 6 8 7 33 2 55 7 4 7 33 2 31 29 DFG 3 1 2 SSE 55 1 2 1 2 55 1 2 3 2 55 1 2 3 2 809 46 DFE 165 3 162 SST 31 29 809 46 840 75 DFT 2 162 164 Example Relaxation Music in PatientControlled Sedation in Colonoscopy Analysis of Variance and F Test for Treatment effects Source of Variation Treatments Error Total Sum of Squares 31 29 809 46 840 75 Degrres of Freedom 2 162 164 Mean Square 15 65 5 00 H0 No differences among Group Means 2 3 HA Group means are not all equal Not all i are equal T S Fobs R R Fobs 15 65 3 13 5 00 F 05 2 162 3 055 Table E P value P F 3 13 0 05 F 3 13 Post hoc Comparisons of Treatments If differences in group means are determined from the F test researchers want to compare pairs of groups Three popular methods include Dunnett s Method Compare active treatments with a control group Consists of I 1 comparisons and utilizes a special table Bonferroni s Method Adjusts individual comparison error rates so that all conclusions will be correct at desired confidence significance level Any number of comparisons can be made Tukey s Method Specifically compares all I I 1 2 pairs of groups Utilizes a special table Bonferroni s Method Most General Wish to make C comparisons of pairs of groups with simultaneous confidence intervals or 2 sided tests Want the overall confidence level for all intervals to be correct to be 95 or the overall type I error rate for all tests to be 0 05 For confidence intervals construct 1 0 05 C 100 CIs for the difference in each pair of group means wider than 95 CIs Conduct each test at 0 05 C significance level rejection region cut offs more extreme than when 0 05 Bonferroni s Method Most General Simultaneous CI s for pairs of group means x x t i j 2c N I 1 1 MSE n n j i If entire interval is positive conclude i j If entire interval is negative conclude i j If interval contains 0 cannot conclude i j Example Relaxation Music in PatientControlled Sedation in Colonoscopy C 3 comparisons 1 vs 2 1 vs 3 2 vs 3 Want all intervals to contain true difference with 95 confidence Will construct 1 0 05 3 100 98 33 CIs for differences among pairs of group means t 05 2 3 162 z 0083 2 40 MSE 5 00 n1 n2 n3 55 1 1 1 1 t 05 2 3 162 MSE 2 40 5 00 1 02 n n 55 55 j i 1vs 2 7 8 6 8 1 02 0 02 2 02 1vs3 7 8 7 4 1 02 0 62 1 42 2vs3 6 8 7 4 1 02 1 62 0 42 Note all intervals contain 0 but first is very close to 0 at lower end CRD with Non Normal Data Kruskal Wallis Test Extension of Wilcoxon Rank Sum Test to I 2 Groups Procedure Rank the observations across groups from smallest 1 to largest N n1 nI adjusting for ties Compute the rank sums for each group R1 RI Note that R1 RI N N 1 2 Kruskal Wallis Test H0 The I population distributions have same distribution HA Not all I distributions are identical 2 12 I Ri i 1 3 N 1 T S H N N 1 ni 2 R R H I 1 2 P value P H Post hoc comparisons of pairs of groups can be made by pairwise application of rank sum test with Bonferroni adjustment Example Thalidomide for Weight Gain in HIV 1 Patients with and without TB I 4 Groups n1 n2 n3 n4 8 patients per group N 32 Group 1 TB patients assigned Thalidomide Group 2 TB patients assigned Thalidomide Group 3 TB patients assigned Placebo Group 4 TB patients assigned Placebo Response 21 day weight gains kg Negative values are weight losses Source Klausner et al 1996 Example Thalidomide for Weight Gain in HIV 1 Patients with and without TB TB Thal 9 0 32 6 0 31 4 5 30 2 0 20 5 2 5 23 3 0 25 1 0 15 5 1 5 18 5 R1 195 5 TB Thal 2 5 23 3 5 26 5 4 0 28 5 1 0 15 5 0 5 12 4 0 28 5 1 5 18 5 2 0 20 5 R2 173 0 TB Plac 0 0 9 …
View Full Document