For n_{a}= n_{b}=
In order to apply the MannWhitney test, the raw data from samples A and B must first be combined into a set of
N=n_{a}+n_{b} elements, which are then ranked from lowest to highest, including tied rank values where appropriate. These rankings are then re
sorted into the two separate samples.
If your data have already been ranked, these ranks can be entered directly into the cells headed by the label «Ranks». In this case, please note that the sum of all ranks for samples A and B combined must be equal to [N(N+1)]/2. If this equality is not satisfied, you will receive a message asking you to examine your data entry for errors.
If your data have not yet been rankordered in this fashion, they can be entered into the cells labeled «Raw Data» and the ranking will be performed automatically. There is also an option, below, for importing raw data from a spreadsheet.
After data have been entered, click one or the other of the «Calculate» buttons according to whether you are starting out with ranks or raw data.
 The value of U reported in this analysis is the one based on sample A, calculated as

 U_{A}
 = n_{a}n_{b} +
 n_{a}(n_{a}+1) 2
 — T_{A}

where T_{A} = the observed sum of ranks for sample A, and

 n_{a}n_{b} +
 n_{a}(n_{a}+1) 2
 = the maximum possible value of T_{A}

 With relatively small samples, the calculated value of U_{A} can be referred directly to the sampling distribution of U_{A}. For cases where n_{a} and n_{b} both fall between 5 and 21, inclusive, the lower and upper limits of the critical intervals of U_{A} are calculated by this page and placed in the designated table below. If either of the samples is of a size smaller than 5, additional instructions will be given below.
 As n_{a} and n_{b} increase, the sampling distribution of T_{A} becomes a reasonably close approximation of the unit normal distribution. If n_{a} and n_{b} are both equal to or greater than 5, this page will also calculate the value of z, along with the corresponding onetailed and twotailed probabilities. Note, however, that the approximation to the normal distribution is best when n_{a} and n_{b} are both equal to or greater than 10.
Option for Importing Raw Data via Copy & Paste:_{T}
Within the spreadsheet application or other source of your data, select and copy the column of data for sample A. Then return to your web browser, click the cursor into the text area for sample A and perform the 'Paste' operation from the 'Edit' menu. Perform the same procedure for sample B. In importing raw data into the MannWhitney test, it is absolutely essential that the numbers of data items for samples A and B are precisely the same as the values of n_{a} and n_{b} that you have specified in setting up this page. For each sample, make sure that the final entry in the list is not followed by a carriage return. To perform this check, click the cursor immediately to the right of the final entry in the list, then press the downarrow key. If an extra line is present, the cursor will move downward. Extra lines can be removed by pressing the downarrow key until the cursor no longer moves, and then pressing the 'Backspace' key (on a Mac platform, 'delete') until the cursor stands immediately to the right of the final entry._{T}
Import Raw Data_{T}
Data Entry:_{T}
Note that mean ranks are provided only for descriptive purposes. They
are not part of the MannWhitney test. ~ Note also that the zratio is
calculated only if n_{a} and n_{b} are both equal to or greater
than 5.