# Nonparametric Statistics

• View
29

0

Embed Size (px)

DESCRIPTION

Nonparametric Statistics. . - PowerPoint PPT Presentation

Transcript

Nonparametric Statistics

Nonparametric Statistics (Rank Data) (Mean) Parameter (Non parametric) 2 Nonparametric parametric In nonparametric tests we hypothesize on the population locations (not necessarily their means).Two populations - same locationTwo populations - different locationsH0 : H1 : 1 2H1 : 1 2H1: 1 216.2 Wilcoxon Rank Sum Test for Independent Samples

1 5% 1 2 Sample 1: 22, 23, 20; Sample 2: 18, 27, 26;:H0: The two population locations are the same.H1: The location of population 1 is to the left of the location of population 2.Sample1RankSample2Rank222320342182726165T1 =9T2 =121 18,20,20,25 1, 2.5, 2.5, 4 2 1 (T1) 9 2(T2) 12 ( T1+T2=21) 1 2 0.05 1 2 T1< 9 7/20 (0.35 35%) P(T< 6) = 0.05 5% If the two populations have the same location (the null hypothesis is true), the value of the statistic T should not be too small.If the T value is small, the null hypothesis should be rejected in favor of the alternative hypothesis.Since P(T Za.

Ranking the raw data

3 1 1,2,3 2 (rank =2)Sum of ranks:T1=276.5T2=188.5To standardize the test statistic we need:E(T) = n1(n1+n2+1)/2= (15)(31)/2=232.5

0.05( 5% ) z=1.645. 5% significance level,

P-value< 0.05 H0

Example 3 (Using Wilcoxon rank sum test with quantitative data) () 25 20 XM16-03

0.05

Solution The problem objective is to compare two populations of quantitative data. The samples are independent. Checking the population samples, we can observe the nonnormality of the variables Non Business graduatesBusiness graduates

123P-value = 0.0105 < 0.05 Null hypothesis

2.1 The Sign TestThis test is employed in the following situations.The problem objective is to compare two populations.The data are ranked.The experimental design is matched pairs.Test statistic.We record the sign of all the matched-pair-differences.The number of positive signs is the test statistic.The number of positive signs is binomially distributed.2. Sign Test and Wilcoxon Signed Rank Sum Test for Matched Pairs Rank (Matched Pairs)

Example 4 25 1 (ride is very uncomfortable) 5 (ride is very comfortable).Notice: The data are ranked. XM16-04The results were:

Do these data allow us to conclude at 5% significance level that the European car is perceived to be more comfortable?SolutionThe hypotheses are:H0: The two population locations are the same.H1: The European cars population is located to the right of the American car populationNot all the dataare shown.There were 18 positives, 5 negatives, and 2 zeros.X = 18, n = 23.Z = [x-np]/[np(1-p)].5 = [18-.5(23)]/[.5[23}.5] =2.71

Normal?The rejection region is z > zaWith a = .05 z.05 = 1.645.

Conclusion: Reject the null hypothesis.There is sufficient evidence to infer thatthe European car is perceived as more comfortable than the American car.

Using the computer: Tools > Data Analysis Plus > Sign Test matched pairs.The test statisticBuild a T statistic based on the sum of differences between paired observations. When n TU or T 30, T is approximately normally distributed. Use a Z-test.2.2 Wilcoxon Signed Rank Sum Test for Matched PairsExample 5 flextime () 32 flextime The hypotheses test areThe two population locations are the same.The two population locations are different.The rejection region:|z| > za/2Number of Nonzero Differences = 32T+ = 367.5T- = 160.5Large Sample ApproximationTest Statistic Z = 1.935P-Value = .0529P-value > 0.05 16.4 Kruskal-Wallis TestThe hypotheses areThe location of all the k populations are the same.At least two population locations differ. Example 6 The Kruskal-Wallis test ( 24 hr) 10 ( 4,3,2,1 )

at 5% significance level?XM16-06Result: P-value = 0.2665 >0.0535 1Certain drugs differ in their side effects depending on the gender of the patient. In a study to determine whether men or women suffer more serious side effects when taking a powerful penicillin substitute, 50 men and 50 women were given the drug. Each was asked to evaluate the level of stomach upset on a 4-point scale, where 4= extremely upset, 3= somewhat upset, 2= not too upset, 1= not upset at all. The results are stored in file XR16-09 with column 1= females evaluation and column2= males eveluation.Can we conclude at the 5% sig. level that men and women experience different levels of stomach upset from the drug? 2 XR16-22 4 1= , 2= , 3= , 4= 150 column1= column2= column3= 5% 3 XR16-25 ? 2 60 10 (1-10) (poor excellent) (Column1= respondent, Column2= , Column3= 10% sig. 4 (XR16-36)3 CAMT section 1 : lecture 2: Case method 3 : Computer software 7 (1-7) (Poor Excellent) section 25 (section 1,2,3 = column1,2,3) 2 (at 5% sig)

Sheet1The drug taken wasPainkillerAspirinextremely effective (5)51quite effective (4)35somewhat effective (3)43slightly effective (2)14not at all effective (1)12

Sheet1PainkillerRankAspirinRank1212261231226312263122631226419.5312419.5312419.5312527419.5527419.5527419.5527419.5527419.5527527

&APage &P

&APage &P

Chart24125130

Frequency

&APage &P

Sheet1

Frequency

Chart12842040

Frequency

&APage &P

Sheet10000000

Frequency

Sheet1RespondentEuropeanAmericanDifference145-122113541432152116532713-284229422102201132112431132111434-115211164311721118431195412031221422223302334-1245232523-1

&APage &P

Sheet1RespondentEuropeanAmericanDifference145-122113541432152116532713-284229422102201132112431132111434-115211164311721118431195412031221422223302334-1245232523-1

&APage &P

Chart11421251

Frequency

Sheet1EuropeanAmericanDifferenceBinBinFrequency45-1-2-21211-1-145410023211112211225532More113-242242222032143121134-121143121143154131242233034-152323-1

&APage &P

Sheet1

Frequency

SIGNTEST2Sign TestABA-B45-1Positive Differences = 18211Negative Differences = 5541Zero Differences = 2321P-Value = 0.005321153213-2422422220321..1..134-121143121143154131242233034-152323-1

Sheet1EuropeanAmerican4521543221531342422232432134214321435431BinBinFrequency42-2-2133-1-143400252111223225More1

&APage &P

Sheet1000000

Frequency

SIGNTEST2Sign TestABA-B45-1Positive Differences = 18211Negative Differences = 5541Zero Differences = 2321P-Value = 0.005321153213-242242222032143121134-121143121143154131242233034-152323-1

Sheet1EuropeanAmerican4521543221531342422232432134214321435431BinBinFrequency42-2-2133-1-143400252111223225More1

&APage &P

Sheet1

Frequency

SIGNTEST2Sign TestABA-B45-1Positive Differences = 18211Negative Differences = 5541Zero Differences = 2321P-Value = 0.005321153213-242242222032143121134-121143121143154131242233034-152323-1

Sheet1EuropeanAmerican4521543221531342422232432134214321435431BinBinFrequency42-2-2133-1-143400252111223225More1

&APage &P

Sheet1

Frequency

Sheet14:00-midMid-8:008:00-4:00433441323422331343334332224331

&APage &P