Nonparametrics for a central value

Example Nonparametrics A random of ten “400-gram soil specimens” were sampled in location A and analyzed for certain contaminant. The sample are the followings: One Sample Inference 65, 54, 66, 70, 72, 68, 64, 51, 81, 49

The contaminant levels are normally distributed. Test the hypothesis, at the level of significance 0.05, that the true contaminant level in this location is different from 50 mg/kg. One sample t-test

NP1 - 2

Advantages of Disadvantages of Nonparametric Nonparametric Procedures Procedures

 May Waste Information  Used With All Scales – Example: Converting Data From Ratio to Ordinal  Make Fewer Assumptions  Need Not Involve Population Parameters  If Data Permit Using Parametric Procedures  Results May Be as Exact as Parametric  Difficult to Compute by Hand for Large Procedures Samples  Tables Not Widely Available

NP1 - 3 NP1 - 4

Confidence Interval For Confidence Interval For Median

The 100(1)% confidence interval for median: Example: (n = 25) 1.4 2.5 2.9 3.1 3.1 3.2 3.9 4.2 4.1 4.4 4.9 5.5 5.8 ( xL , xU ) where L = C(2), n+ 1, U = n  C(2), n 6.1 6.3 6.6 7.6 7.2 7.2 7.3 11.3 19.4 20.1 24.9 30.1 Check Table 4 in the Ott’s book for C(2), n ; and xL and th th Find the 95% confidence interval for median. xU are the L and U order .

C(2), n are from a with p = 0.5. C(2), n = C.05 ,25 = 7, L = C(2), n+ 1 = C.05 ,25 + 1 = 8

U = n  C(2), n = 25  C.05 ,25 = 18 In Table 4: (2) =  , (1) = /2 The 95% C.I. for median is: ( x8 , x18 ) = (4.2, 7.2) For 95% C.I.: (2) = .05, (1) = .025 n n Large Sample approx.: C(2), n   z NP1 - 5 2 2 4 NP1 - 6

NP - 1 Nonparametrics for a central value

H0 : h = 50 Ha : h > 50 The Use of Sign Test (Binomial Test) h is median.

65, 54, 66, 70, 72, 68, 64, 49, 81, 48 • Tests One Population Median, h (eta) Ordered List • Corresponds to t-Test for One Mean  48, 49, 54, 64, 65, 66, 68, 70, 72, 81 • Assumes Population Is Continuous

• Small Sample Test : # Sample Values   + + + + + + + + Above (or Below) Median • Can Use Normal Approximation If n  10

NP1 - 7 NP1 - 8

Sign Test for a Population Median h Sign Test for a Population Median H : h = h (or Binomial Test) 0 0 Ha: h < h0 (or h > h0 , h  h0)

Test Statistic: S = # of sample measurements less than h , if H : h < h , or Binomial probability density mass function: 0 a 0 S = # of sample measurements greater than h0, if Ha: h > h0 , or S = Larger of S1 and S2, where S1 is the # of measurements less

n x nx than h0 and S2 is the # of measurements greater than h0, P(X  x)    p (1p ) if H : h  h x a 0   n! x nx Observed significant level: (Use Binomial p.m.f., n, p = 0.50)  p (1p ) p-value = P(X  S), if H : h < h (or h > h ) x!(n  x)! a 0 0 p-value = 2P(X  S), if Ha: h  h0 (Drop the ties. So the size n used may be less than actual sample size.) Reject H if p-value < . NP1 - 9 0 NP1 - 10

H0 : h = 50 Ha : h > 50 Sign Test (Binomial Test) h is median. Sign Test SPSS Output

65, 54, 66, 70, 72, 68, 64, 49, 81, 48 Binomial Test S = 8 Ordered List Observed Exact Sig.  48, 49, 54, 64, 65, 66, 68, 70, 72, 81 Category N Prop. Test Prop. (2-tailed) Contaminant Level Group 1 <= 50 2 .20 .50 .109   + + + + + + + + Group 2 > 50 8 .80 Total 10 1.00 n = 10, p = .5  P(X  8) = .0547 [= P(X  2)] Median of the distribution is not significantly different (p-value if H : h > 50.) a from 50 mg/kg. For Two-Sided Test : p-value = 2 x P(X  8) = .109 NP1 - 11 NP1 - 12

NP - 2 Nonparametrics for a central value

Large-Sample Sign Test for a Population Median Example: To determine the median life span of certain species of (Assumption: The sample is randomly selected from a continuous animal is greater than 5 years, a random sample of 25 distribution) observations were made and life span in year is the following:

H0: h = h0 Ha: h < h0 (or h > h0 , h  h0) 11.3 5.8 3.1 4.1 7.3 4.4 1.4 2.5 6.6 7.6 24.9 30.1 2.9

(S .5)  (n / 2) (S .5) .5n 5.5 7.2 3.2 3.9 7.2 20.1 3.1 6.1 4.9 19.4 4.2 6.3 Test Statistic: z (  n / 4 .5 n At 0.05 level of significant, use sign test to test if the median life span is greater than 5 years. ( is npq  n (. 5 )(. 5 )  n / 4 ) where H0: h = 5 H : h > 5 S = # of measurements less than h0 if Ha: h < h0 , or a 14 .5).525 S = # of measurements greater than h0 if Ha: h > h0 , or Test Statistic: S = 14 (# of “+” signs), z  = 0.4 S = Larger of S1 and S2, where p-value = P(Z > 0.4) = .3446 > .05 .5 25 S1 is the # of measurements less than h0 and Conclusion: Fail to reject H0. There is no sufficient evidence to S2 is the # of measurements greater than h0, if Ha: h  h0 support that the median life span is greater than 5 yrs. NP1 - 13 NP1 - 14

NP - 3