Download presentation
Presentation is loading. Please wait.
1
Lesson #25 Nonparametric Tests for a Single Population
2
Nonparametric (distribution free) tests do not assume that data are from any specific distribution. no assumption of Normality Advantages - Good tests to use with small sample sizes, - “robust” with regard to “outliers” - almost as powerful as Normal-theory tests even if data are from Normal distribution(s) since Central Limit Theorem doesn’t apply
3
Tests for Location, One Sample Nonparametric alternatives to a one-sample t-test, (or paired t-test) Look at two tests - - Sign test - Wilcoxon Signed Rank test Test H 0 : M = M 0 against some alternative, where M is the population median (Can also be used with two paired samples)
4
Sign Test The test statistic is D, the number of “successes”, which is the number of observations above M 0 - assume that data are from a continuous dist. Let any observation above M 0 be a “success”, and any observation below M 0 be a “failure” Discard any observations that equal M 0, adjust n (Paired data, D = number of positive differences)
5
If H 0 is true, P(“success”) = P(obs. > M 0 )=.5 Then, D ~ B(n,.5) under H 0 Calculate the p-value directly, using the Binomial distribution with parameters n and p =.5. H 1 : M > M 0 p-value = P(X > D) Let X ~ B(n,.5) H 1 : M < M 0 p-value = P(X < D) H 1 : M M 0 p-value = 2P(X < C) where C = min(D, n-D)
6
Test, at =.05, if median age of students finishing a Masters degree in biostatistics is greater than 25. H 0 : M = 25H 1 : M > 25 Age 26 30 37 23 42 25 28 33 28 Age-25 1 5 12 -2 17 0 3 8 3
7
Test, at =.05, if median age of students finishing a Masters degree in biostatistics is greater than 25. H 0 : M = 25H 1 : M > 25 Age 26 30 37 23 42 25 28 33 28 Age-25 1 5 12 -2 17 0 3 8 3 D = 7 p-value = P(X > 7)=.0352 Reject H 0 Conclude median age of all such graduates is greater than 25
8
Wilcoxon Signed Rank Test - assume distribution is continuous and symmetric Discard any observation(s) that equal M 0, adjust n (Paired data, look at differences within pairs) Again look at the differences between the observations and the null value, M 0 Rank the absolute values of the differences, from low to high Ties receive the average rank
9
T + = sum of the ranks of the positive differences T - = sum of the ranks of the negative differences T = min(T +, T - ) p-values for one-sided tests are in Table A.6 - only if results are in correct “direction” - if not, actual p-value is 1-(table value) Double the table value to get the p-value for a two-sided test
10
Test, at =.05, if median age of students finishing a Masters degree in biostatistics is greater than 25. H 0 : M = 25H 1 : M > 25 Age 26 30 37 23 42 25 28 33 28 Age-25 1 5 12 -2 17 0 3 8 3 Rank 1 2 3.5 5 6 7 8 T + = 34 T - = 2 T = 2 p-value =.0118
11
In SAS, use PROC UNIVARIATE For Sign test, SAS displays M = D - n/2 For Wilcoxon Signed Rank test, SAS displays Example: M = 7 - 8/2 = 3 This gives p-values for two-sided tests
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.