rankColumns {cTRAP} | R Documentation

## Rank columns in a dataset

### Description

Rank columns in a dataset

### Usage

    rankColumns(table, rankingInfo, rankByAscending = TRUE, sort = FALSE)

### Arguments

`table` | Data table: data; first column must be identifiers
`rankingInfo` | Data table: boolean values of which rows to rank based on columns (column names to be ranked must exactly match those available in argument `table`); first column must be identifiers
`rankByAscending` | Boolean: rank values based on their ascending (`TRUE`) or descending (`FALSE`) order?
`sort` | Boolean: sort data based on rank product's rank (if multiple methods are available) or by available ranks

### Details

The rank product's rank is calculated if more than one method is ranked.

### Value

Data table with the contents of `table` and extra columns with respective rankings

### Note

The first column of `data` and `rankingInfo` must contain common identifiers.

[Package cTRAP version 1.12.0 Index]