version 1.0.0 (3.41 KB) by Andrew Penn
Tied-rank transformation across both dimensions


Updated Thu, 08 Aug 2019 14:26:54 +0000

View License

Function: tiedrank2


The entire data matrix X is ranked from smallest to largest, where average ranks are assigned in the case of ties and NaN values are ignored. This is what Conover referred to as the RT-1 type procedure [1].

If there is more than one observation per row-column "cell", use the scalar argument REPS to indicate the (largest) number of observations per cell. Each cell corresponds to REPS consecutive rows in one column of X if DIM equals 1 (default), or REPS consecutive columns in one row of X if DIM equals 2.

The output from tiedrank2 can be used as input for the ANOVA functions as a more powerful alternative to using bespoke nonparametric tests [2].

Please see function help for example usage in a wide variety of tests.

[1] Conover, W. J., & Iman, R. L. (1981).
Rank transformations as a bridge between parametric and nonparametric statistics.
American Statistician, 35, 124-129.

[2] Zimmerman, D. W., & Zumbo, Bruno, D. (1993).
Relative power of the Wilcoxon test, the Friedman test, and repeated-measures ANOVA on ranks.
Journal of Experimental Education, 62, 75-86.

[3] Conover, W. J., & Iman, R. L. (1982).
Analysis of Covariance using the Rank Transformations.
Biometrics, 38, 715-724.

Cite As

Andrew Penn (2022). tiedrank2 (https://www.mathworks.com/matlabcentral/fileexchange/72399-tiedrank2), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2019a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Tags Add Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!