Learn R Programming

pmr (version 1.2.5)

rankagg: Summary of a ranking dataset.

Description

Turn individual rankings into a summary matrix.

Usage

rankagg(dset)

Arguments

dset
each row represent a single ranking

Value

Return the dataset which summarize the original ranking data.

Examples

Run this code
## create an artificial dataset
X1 <- c(1,1,2,2,3,3)
X2 <- c(2,3,1,3,1,2)
X3 <- c(3,2,3,1,2,1)
test <- data.frame(X1,X2,X3)

## aggregate the ranking of all the observations and create a summary matrix
## test2 <- rankagg(test)

Run the code above in your browser using DataLab