MerQuR+Statistics Glossary

Statistics Glossary → Ties and zero differences (rank tests)

Ties and zero differences (rank tests)concept

In rank-based tests, observations sharing the same value (ties) and, in paired data, pairs whose difference is exactly zero; both require special handling of the test statistic.

Rank tests such as Mann-Whitney, Kruskal-Wallis, Wilcoxon and Spearman convert the data into ranks. When two or more observations share the same value, each receives the average of the ranks they occupy (two equal values in positions 4 and 5 each get 4.5). Because ties reduce the variance of the ranks, the variance of the test statistic is recomputed with a tie correction; otherwise the p value comes out too large. With many ties (e.g. five-point Likert items), exact p-value tables no longer apply and a normal approximation or permutation is used.

The Wilcoxon signed-rank test also faces the problem of zero differences: a pair whose before and after values are identical has no sign. The classical Wilcoxon approach drops these pairs and reduces n; Pratt's (1959) method includes the zeros in the ranking but leaves their ranks out of the statistic; the 'zsplit' approach splits the zeros' ranks equally between the positive and negative sums. With many zero differences the three methods can give different results, and the method chosen should be reported. The sign test also usually excludes zero differences.

An everyday example

A teacher compares the 1-to-5 satisfaction scores that 30 pupils gave before and after a training course. Ten pupils' scores did not change at all (zero differences), and most of those that changed moved by only 1 or 2 points (many ties). Since dropping these ten pupils or including them in the ranking can change the result, the method used should be stated.

In MerQur

It is chosen with the 'Zero differences (wilcox, pratt, zsplit)' parameter in the Wilcoxon Signed-Rank test. Tie corrections are applied in analyses such as Mann-Whitney U, Kruskal-Wallis, Friedman, the Sign and Runs tests, Correlation Analysis (Kendall τ-b), the Mann-Kendall test and Multidimensional Scaling; in Cox regression, Time-Dependent Cox, Competing Risks, Survey-PHREG and Cluster-Robust Cox a 'Ties method' is chosen for events occurring at the same time (Efron, Breslow; in Cox and Time-Dependent Cox also Exact).

Analyses where this concept appears

Mann-Whitney UWilcoxon Signed-RankKruskal-WallisFriedmanSign TestRuns TestCorrelation AnalysisMultidimensional Scaling (MDS)Conditional Logit (Choice Model)Cox Regression (Proportional Hazards Model)Competing RisksTime-dependent Cox RegressionSurvey-PHREG (Weighted Cox)Cluster-Robust Cox (Marginal and Frailty Models)Mann-Kendall + Sen's SlopeLOESS (Local Regression)

Related concepts

Exact test and exact p-valuePermutation p-value