Introduction to Statistics in Psychology PSY 201 Professor Greg Francis Lecture 29 Hypothesis testing for two sample case other statistics What do people think about death HYPOTHESES DEPENDENT SAMPLES EXAMPLE when the samples are not independent hypothesis testing of proportions becomes a bit more complicated Testing the difference of proportions of individuals who pass each of two similar items on a test e g comparing pass fail for two sets of students who get better than 600 SAT samples are dependent when each score in one sample is paired with a score in the other sample just like dependent samples for the mean the problem is that the samples are not independent not truly random and we need to take that into account Comparing proportions of husbands and wives on an issue 2 3 SAMPLING DISTRIBUTION CONTINGENCY TABLE for dependent samples we let p P1 P2 so our hypotheses become we need to know the sampling distribution and the standard error H0 p P1 P2 0 but first we need to design a contingency table which shows disagreement or dissimilarity in responses Ha p P1 P2 0 Test the difference in proportions of individuals who support something before and after discussion Group 1 NO YES Group YES A B A B 2 NO C D C D A C B D A B C D n A is the number of scores that are no in group 1 and yes in group 2 B is the number of scores that are yes in group 1 and yes in group 2 C is the number of scores that are no in group 1 and no in group 2 we then convert these to proportions Group 1 NO YES Group YES a b a b 2 NO c d c d a c b d a b c d 1 0 a A n is the proportion of scores that are no in group 1 and yes in group 2 b B n is the proportion of scores that are yes in group 1 and yes in group 2 c C n is the proportion of scores that are no in group 1 and no in group 2 d D n is the proportion of scores that are yes in group 1 and no in group 2 D is the number of scores that are yes in group 1 and no in group 2 4 5 6 PROPORTIONS CONTINGENCY TABLES HYPOTHESIS TESTING from the contingency table we can get the proportions of scores with the trait we are interested in the sampling distribution is approximately normal with a mean of P1 P2 if so to actually carry out the test we get the critical value zcv for the corresponding bottom row of t distribution table or and compare it to the test statistic p p2 p z 1 sp1 p2 or since our null hypothesis is that p 0 this is what we need for our statistic B D p1 b d n A B p2 a b n but we also need the contingency table for other reasons A D 10 B C 10 if not do not use this test moreover our estimate of standard error of the difference between dependent proportions is a d n which we get from the contingency table sp1 p2 z p1 p2 sp1 p2 7 8 9 SHORT CUT EXAMPLE EXAMPLE with some algebra you can show that the formula for the test statistic is also A D z A D where A and D are the frequencies from the contingency table I want to know if there is a difference in the proportion of students that support support gun control Group 1 and and the proportion of students that support the death penalty Group 2 Raise your hand if this saves the trouble of calculating sp1 p2 but if you want to calculate confidence intervals you will need the standard error 10 One a sheet of paper answer these questions you do not have to be honest if you do not want other people to know your views A You do not support gun control but support prohibiting the death penalty no yes B You support gun control and prohibiting the death penalty yes yes C You do not support gun control and do not support prohibiting the death penalty no no D You support gun control but do not support prohibiting the death penalty yes no Do you support legislation to restrict the ownership of guns Do you support legislation to prohibit the death penalty for convicted felons 11 12 CONTINGENCY TABLE PROHIBIT DEATH PENALTY NO YES GUN YES CONTROL NO CRITERION PROPORTIONS I need to check if I can use the normal approximation to the sampling distribution I can calculate proportions B D p1 b d n A B p2 a b n I want to test check if H 0 P1 P2 0 A D 10 Ha P1 P2 0 I will use 0 05 and a two tailed test Note Group 1 is the set of responses to the question about restricting gun ownership Group 2 is the set of responses to the question about or B C 10 if not do not use this test if successful then for 0 05 I find from the bottom row of the t distribution table that I could calculate the standard error as a b sp1 p2 n and then calculate the test statistic p p2 z 1 sp1 p2 but I prefer to use the short cut prohibiting the death penalty zcv 1 96 13 14 15 SHORT CUT INTERPRETATION CONCLUSIONS If we reject H0 that indicates the probability of getting the difference of proportions when the population parameters were equal is less than 0 05 We interpret that as meaning the population parameters are different two sample case A D z A D compare to the critical value z zcv make decision 16 dependent proportions If we fail to reject H0 that indicates the probability of getting the difference of proportions when the population parameters were equal is greater than 0 05 We do not have strong enough evidence to conclude that the population parameters are different 17 18 NEXT TIME power designing experiments Seeing statistically 19
View Full Document
Unlocking...