You are on page 1of 15

Nonparametric Methods:

Analysis of Ranked Data

Chapter 18

McGraw-Hill/Irwin Copyright © 2012 by The McGraw-Hill Companies, Inc. All rights reserved.
Learning Objectives
LO1 Define a nonparametric test and when it is applied
LO2 Conduct the sign test for dependent samples using the binomial
and standard normal distributions as the test statistics.
LO3 Conduct a test of hypothesis for dependent samples using the
Wilcoxon signed-rank test.
LO4 Conduct and interpret the Wilcoxon rank-sum test for independent
samples.
LO5 Conduct and interpret the Kruskal-Wallis test for several
independent samples.
LO6 Compute and interpret Spearman’s coefficient of rank correlation.
LO7 Conduct a test of hypothesis to determine whether the correlation
among the ranks in the population is different from zero.

18-2
LO2 Conduct the sign test for dependent samples using the
binomial and standard normal distributions as the test statistics.

The Sign Test


EXAMPLE
 The Sign Test is based on the sign of a The director of information systems at Samuelson Chemicals
recommended that an in-plant training program be instituted for
difference between two related managers. The objective is to improve the knowledge of database
observations. usage in accounting, procurement, production, and so on. A
 Assumption regarding the shape of the sample of 15 managers was selected at random. A panel of
database experts determined the general level of competence of
population of differences is NOT each manager with respect to using the database. Their
necessary. competence and understanding were rated as being either
 The binomial distribution is the test outstanding, excellent, good, fair, or poor. After the three-month
training program, the same panel of information systems experts
statistic for small samples and the rated each manager again. The two ratings (before and after) are
standard normal (z) for large samples. shown along with the sign of the difference. A “+” sign indicates
 The test requires dependent (related) improvement, and a “-” sign indicates that the manager’s
competence using databases had declined after the training
samples. program.

Procedure to conduct the test: Did the in-plant training program effectively increase the
competence of the managers using the company’s database?
 Determine the sign (+ or -) of the
difference between pairs.
 Determine the number of usable pairs.
 Compare the number of positive (or
negative) differences to the critical
value.
 n is the number of usable pairs (without
ties), X is the number of pluses or
minuses, and the binomial probability
 π = .5
18-3
LO2

The Sign Test –


Example
Step 1: State the Null and Alternative
Hypotheses

H0: π ≤.5 (There is no increase in competence


as a result of the in-plant training program.)
H1: π >.5 (There is an increase in competence
as a result of the in-plant training program.)

Step 2: Select a level of significance.


We chose the .10 level.

Step 3: Decide on the test statistic.


It is the number of plus signs resulting
from the experiment.

Step 4: Formulate a decision rule. In this example


α is .10.
 The probability of 3 or fewer successes is
.029, found by .000 + .001 + .006 + .022.
 The probability of 11 or more successes is Step 5: Make a decision regarding the null hypothesis.
also .029. Adding the two probabilities gives Eleven out of the 14 managers in the training course increased their
.058. This is the closest we can come to .10 database competency. The number 11 is in the rejection region, which
without exceeding it. starts at 10, so the null hypothesis is rejected.
 Hence, the decision rule for a two-tailed test
would be to reject the null hypothesis if there We conclude that the three-month training course was effective. It
are 3 or fewer plus signs, or 11 or more plus increased the database competency of the managers.
signs. 18-4
LO2

Normal Approximation
 If the number of observations in the sample is larger than 10, the normal distribution can be used to
approximate the binomial.

EXAMPLE Step 3: Select the test statistic.


The market research department of Cola, Inc., has been given Use Z-distribution
the assignment of testing a new soft drink. Two versions of the where µ=.50n and σ=.50 n
drink are considered—a rather sweet drink and a somewhat
bitter one. A preference test is to be conducted consisting of a Step 4: Formulate the decision rule.
sample of 64 consumers. Each consumer will taste both the Referring to Appendix B.1, Areas under the Normal Curve,
sweet cola (labeled A) and the bitter one (labeled B) and for a two-tailed test (because states that π ≠ .50), at the .05
indicate a preference. Conduct a test of hypothesis to significance level, the critical values are -1.96 and +1.96.
determine if there is a difference in the preference for the sweet
and bitter tastes. Use the .05 significance level. Step 5: Compute z, compare the computed value with
the critical value, and make a decision regarding H0
Preference for cola A was given a “+”sign and preference for
Step 1: State the null hypothesis and the alternate
B a “-” sign. Out of the 64 in the sample, 42 preferred the
hypothesis.
sweet taste, which is cola A. Therefore, there are 42 pluses.
H0: π = .50 There is no preference Since 42 is more than n/2 =64/2=32, we use:
H1: π ≠ .50 There is a preference ( X  .50 )  .50n ( 42  .50 )  .50( 64 )
z   2.38
.50 n 0.50 64
Step 2: Select the level of significance.
The computed z of 2.38 is beyond the critical value of 1.96.
α = 0.05 as stated in the problem Conclusion: The null hypothesis of no difference is rejected at the .05
significance level. There is evidence of a difference in consumer
preference. That is, we conclude consumers prefer one cola over
another. 18-5
LO3 Conduct a test of hypothesis for dependent
samples using the Wilcoxon signed-rank test.

Wilcoxon Signed-Rank Test for Dependent Samples

If the assumption of normality is EXAMPLE


violated for the paired-t test, use Fricker’s is a family restaurant chain located primarily in the
southeastern part of the United States. It offers a full dinner menu,
the Wilcoxon Signed-rank test. but its specialty is chicken. Recently, Fricker, the owner and
 The test requires the ordinal scale founder, developed a new spicy flavor for the batter in which the
of measurement. chicken is cooked. Before replacing the current flavor, he wants to
conduct some tests to be sure that patrons will like the spicy flavor
 The observations must be related better. Bernie selects a random sample of 15 customers, each
or dependent. customer is given a small piece of the current chicken and asked
to rate its overall taste on a scale of 1 to 20. A value near 20
indicates the participant liked the flavor, whereas a score near 0
The steps for the test are: indicates they did not like the flavor. Next, the same 15 participants
are given a sample of the new chicken with the spicier flavor and
1. Compute the differences between again asked to rate its taste on a scale of 1 to 20.
related observations. Drop The results are reported in the table below. Is it reasonable to
observations with 0 difference conclude that the spicy flavor is preferred? Use the .05
from the sample. significance level.
2. Rank the absolute differences
from low to high.
3. Return the signs to the ranks and
sum positive and negative ranks.
4. Compare the smaller of the two
rank sums with the T value,
obtained from Appendix B.7.

18-6
LO3

Wilcoxon Signed-Rank Test for Dependent


Samples - Example
Hypothesis:
H0: There is no difference in the
ratings of the two flavors.
H1: The spicy ratings are higher.

Decision Rule:
Reject H0 if decision rule is to
reject the null hypothesis if the
smaller of the rank sums is 25 or
less.
Computed T = 30
Critical T = 25

Decision is not to reject the null


hypothesis.
We cannot conclude there is a
difference in the flavor ratings
The smaller of the two rank sums is used as the test statistic and between the current and the
referred to as T. spicy.

18-7
LO3

Wilcoxon Signed-Rank Test for Dependent


Samples - Example

 The critical values for the Wilcoxon signed-rank test are


located in Appendix B.7. A portion of that table is shown
on the table below.

18-8
LO4 Conduct and interpret the Wilcoxon rank-
sum test for independent samples.

Wilcoxon Rank-Sum Test for Independent


Samples
 The Wilcoxon Rank-Sum Test is used to determine if two independent samples came from the same or
equal populations.
 No assumption about the shape of the population is required.
 The data must be at least ordinal scale.
 Each sample must contain at least eight observations.
 To determine the value of the test statistic W, all data values are ranked from low to high as if they were
from a single population.
 The sum of ranks for each of the two samples is determined.
 The data are ranked as if the observations were part of a single sample.
 The sum of ranks for each of the two samples is determined
 If the null hypothesis is true, then the ranks will be about evenly distributed between the two samples, and
the sum of the ranks for the two samples will be about the same.

18-9
LO4

Wilcoxon Rank-Sum Test for Independent


Samples - Example
Dan Thompson, the president of Set up Hypothesis and Decision Rule:
CEO Airlines, recently noted an Hypothesis:
increase in the number of no- H0: The population distribution of no-shows is the same or
shows for flights out of Atlanta. less for Atlanta and Chicago.
He is particularly interested in H1: The population distribution of no-shows is larger for
determining whether there are Atlanta than for Chicago.
more no-shows for flights that Decision Rule: Reject H0 if: computed Z > critical Z
originate from Atlanta compared .05 level of significance = 1.65 critical Z
with flights leaving Chicago. A
sample of nine flights from Rank the observations from both samples as if they were a single
Atlanta and eight from Chicago
are reported on table. group.
At the .05 significance level, can
we conclude that there are more
no-shows for the flights
originating in Atlanta?

The Chicago flight with only 8 no-shows had the fewest, so it is assigned
a rank of 1. The Chicago flight with 9 no-shows is ranked 2, and so
on.

18-10
LO4

Wilcoxon Rank-Sum Test for Independent


Samples - Example
The value of W is calculated for the Atlanta group and is found to be 96.5, which is the sum of the ranks
for the no-shows for the Atlanta flights.

The computed z value (1.49) is less than 1.65, the null hypothesis is not
rejected. It appears that the number of no-shows is the same in Atlanta as in Chicago.

18-11
LO5 Conduct and interpret the Kruskal-Wallis
test for several independent samples.
Kruskal-Wallis Test:
Analysis of Variance by Ranks
EXAMPLE
A management seminar consists of executives from manufacturing,
This is used to compare three finance, and engineering. Before scheduling the seminar sessions, the
or more samples to determine seminar leader is interested in whether the three groups are equally
if they came from equal knowledgeable about management principles. Plans are to take samples
of the executives in manufacturing, in finance, and in engineering and to
populations. administer a test to each executive. If there is no difference in the scores
for the three distributions, the seminar leader will conduct just one
 The ordinal scale of session. However, if there is a difference in the scores, separate sessions
measurement is required. will be given. We will use the Kruskal-Wallis test instead of ANOVA
because the seminar leader is unwilling to assume that (1) the
 It is an alternative to the one- populations of management scores follow the normal distribution or (2)
way ANOVA. the population standard deviations are the same.
 The chi-square distribution is
the test statistic. Step 1: Set up the Null and Alternate Hypotheses
 Each sample should have at H0: The population distributions of the management scores for
least five observations. the populations of executives in manufacturing, finance,
 The sample data is ranked and engineering are the same.
from low to high as if it were a H1: The population distributions of the management scores for
single group. the populations of executives in manufacturing, finance,
and engineering are NOT the same.

Step 2: State the Decision Rule


H0 is rejected if the computed H statistic is greater than critical χ2
value of 5.991 (There are 2 degrees of freedom at the .05
significance level.)

18-12
LO5
Kruskal-Wallis Test:
Analysis of Variance by Ranks - Example

Step 3: Collect Data and Compute the Chi-square Statistic


Considering the scores as a single population, the engineering executive with a score of 35 is the lowest,
so it is ranked 1. There are two scores of 38. To resolve this tie, each score is given a rank of 2.5, found
by (2+3)/2. This process is continued for all scores.
The scores, the ranks, and the sum of the ranks for each of the three samples are given in the table
below.

Because the computed value of


H (5.736) is less than the critical
value of 5.991, the null
hypothesis is not rejected.

There is not enough evidence to


conclude there is a difference
among the executives from
manufacturing, finance, and
engineering with respect to their
typical knowledge of
management principles.

18-13
LO6 Compute and interpret Spearman’s
coefficient of rank correlation.

Rank-Order Correlation
EXAMPLE
Spearman’s coefficient of rank Lorrenger Plastics, Inc., recruits management
correlation reports the trainees at colleges and universities throughout
association between two sets of the United States. Each trainee is given a rating
ranked observations. The by the recruiter during the on-campus interview.
features are: This rating is an expression of future potential
and may range from 0 to 15, with the higher
score indicating more potential. The recent
 It can range from –1.00 up to college graduate then enters an in-plant training
program and is given another composite rating
1.00. based on tests, opinions of group leaders,
training officers, and so on. The on-campus rating
and the in-plant training ratings are given in the
 It is similar to Pearson’s table on the right.
coefficient of correlation, but is
based on ranked data.

 It computed using the formula:

18-14
LO6

Rank-Order Correlation - Example

Conclusion:

The value of .726 indicates a strong positive association between the ratings of the on-campus recruiter and the
ratings of the training staff.

The graduates that received high ratings from the on-campus recruiter also tended to be the ones that received high
ratings from the training staff.`

18-15

You might also like