Learn R Programming

scmamp (version 0.2.55)

rankMatrix: Get the ranking matrix.

Description

This function returns, given a matrix, the ranking of the colums in each row.

Usage

rankMatrix(data, decreasing = TRUE, ...)

Arguments

data
The matrix to rank.
decreasing
Logical value indicating whether the top ranked has to be the highest value or not.
...
Not used

Value

A matrix containing the per-row rankings. In case of ties, the mean rank is obtained (e.g, if there is a tie between the 4th and the 5th column, both are assigned a mean rank of 4.5)

Examples

Run this code
data(data_gh_2008)
rankMatrix(data.gh.2008)

Run the code above in your browser using DataLab