Presentation is loading. Please wait.

Presentation is loading. Please wait.

Inferences Between Two Variables

Similar presentations


Presentation on theme: "Inferences Between Two Variables"— Presentation transcript:

1 Inferences Between Two Variables
Lesson Inferences Between Two Variables

2 Objectives Perform Spearman’s rank-correlation test

3 rs = 1 – -------------- n(n²- 1)
Vocabulary Rank-correlation test -- nonparametric procedure used to test claims regarding association between two variables. Spearman’s rank-correlation coefficient -- test statistic, rs 6Σdi² rs = 1 – n(n²- 1)

4 Association Parametric test for correlation:
Assumption of bivariate normal is difficult to verify Used regression instead to test whether the slope is significantly different from 0 Nonparametric case for association: Compare the relationship between two variables without assuming that they are bivariate normal Perform a nonparametric test of whether the association is 0

5 Tale of Two Associations
Similar to our previous hypothesis tests, we can have a two-tailed, a left-tailed, or a right-tailed alternate hypothesis A two-tailed alternative hypothesis corresponds to a test of association A left-tailed alternative hypothesis corresponds to a test of negative association A right-tailed alternative hypothesis corresponds to a test of positive association

6 Test Statistic for Spearman’s Rank-Correlation Test
Small Sample Case: (n ≤ 100) The test statistic will depend on the size of the sample, n, and on the sum of the squared differences (di²). 6Σdi² rs = 1 – n(n²- 1) where di = the difference in the ranks of the two observations (Yi – Xi) in the ith ordered pair. Spearman’s rank-correlation coefficient, rs, is our test statistic z0 = rs √n – 1 Large Sample Case: (n > 100)

7 Critical Value for Spearman’s Rank-Correlation Test
Small Sample Case: (n ≤ 100) Using α as the level of significance, the critical value(s) is (are) obtained from Table XIII in Appendix A. For a two-tailed test, be sure to divide the level of significance, α, by 2. Large Sample Case: (n > 100) Left-Tailed Two-Tailed Right-Tailed Significance α α/2 Decision Rule Reject if rs < -CV Reject if rs < -CV or rs > CV Reject if rs > CV

8 Hypothesis Tests Using Spearman’s Rank-Correlation Test
Step 0 Requirements: 1. The data are a random sample of n ordered pairs. 2. Each pair of observations is two measurements taken on the same individual Step 1 Hypotheses: (claim is made regarding relationship between two variables, X and Y) H0: see below Ha: see below Step 2 Ranks: Rank the X-values, and rank the Y-values. Compute the differences between ranks and then square these differences. Compute the sum of the squared differences. Step 3 Level of Significance: (level of significance determines the critical value) Table XIII in Appendix A. (see below) Step 4 Compute Test Statistic: Step 5 Critical Value Comparison: 6Σdi² rs = 1 – n(n²- 1) Left-Tailed Two-Tailed Right-Tailed Significance α α/2 H0 not associated Ha negatively associated associated positively associated Decision Rule Reject if rs < -CV Reject if rs < -CV or rs > CV Reject if rs > CV

9 Expectations If X and Y were positively associated, then
Small ranks of X would tend to correspond to small ranks of Y Large ranks of X would tend to correspond to large ranks of Y The differences would tend to be small positive and small negative values The squared differences would tend to be small numbers If X and Y were negatively associated, then Small ranks of X would tend to correspond to large ranks of Y Large ranks of X would tend to correspond to small ranks of Y The differences would tend to be large positive and large negative values The squared differences would tend to be large numbers

10 Example 1 from 15.6 Calculations: S D S-Rank D-Rank dif = X - Y dif²
100 257 2.5 1 1.5 2.25 102 264 5 4 103 274 6 101 266 -1 105 277 7.5 8 -0.5 0.25 263 3 99 258 2 275 7 0.5 267 Ave Sum

11 Example 1 Continued Hypothesis: H0: X and Y are not associated Ha: X and Y are associated Test Statistic: (Two-tailed) Σdi² (6) rs = = 1 – = = n(n² - 1) (64 - 1) (63) Critical Value: (from table XIII) Conclusion: Since rs > CV, we reject H0; therefore there is a relationship between club-head speed and distance.

12 HyCCI for Example 1 Hyp: H0: Club head speed and distance are not associated Ha: Club head speed and distance are associated Conditions: Assume an independent random sample Paired data (explanatory, response) from each golfer Calculations: (Two-tailed) Σdi² (6) rs = = 1 – = = n(n² - 1) (64 - 1) (63) Critical Value: (from table XIII) Interpretation: Since rs > CV, we reject H0; therefore there is a relationship between club-head speed and distance.

13 Example done in Excel Club-Head Speed Distance Rank - X Rank - Y
difference 100 257 2.5 1 1.5 2.25 102 264 5 4 103 274 6 101 266 -1 105 277 7.5 8 -0.5 0.25 263 3 99 258 2 275 7 0.5 n = sum rs = rc = 0.738

14 Summary and Homework Summary Homework
Spearman rank-correlation test is a nonparametric test for testing the association of two variables Test is a comparison of the ranks of the paired data values Critical values for small samples are given in tables Critical values for large samples can be approximated by a calculation with the normal distribution Homework problems 3, 6, 7, 10 from the CD

15 Homework Problem 3 Problem 3 X Y Rank - X Rank - Y difference d2 2 1.4
4 1.8 8 2.1 3.5 3 0.5 0.25 2.3 -0.5 9 2.6 5 n = sum rs = 0.975 rc = FTR

16 Homework Problem 6 Problem 6 X Y Rank - X Rank - Y difference d2 0.8 1
0.8 1 0.5 2.3 2 3 -1 1.4 1.9 3.5 1.5 2.25 2.5 4 -0.5 0.25 3.9 5 4.6 6.8 6 n = sum rs = 0.9 rc = 0.886 Reject

17 Homework Problem 7 Problem 7 BS % Income Rank - X Rank - Y difference
17.4 24289 1 29.8 33749 9 24.6 29043 4 22.3 26100 2 23.7 28831 3 26.8 30758 8 25 29944 6 7 -1 26.4 29340 5 24.7 29372 n = sum rs = 0.95 rc = 0.6 Reject

18 Homework Problem 10 Problem 10 Standings Yards Rank - X Rank - Y
difference d2 12 4803 5 3 2 4 30 5215 7 6 1 4459 11 5134 -1 4972 -2 29 5936 4134 n = sum rs = rc = 0.714 Reject


Download ppt "Inferences Between Two Variables"

Similar presentations


Ads by Google