## Five input rankings with five objects
input_rkgs <- matrix(c(3, 2, 5, 4, 1, 2, 3, 1, 5, 4, 2, 3, 1, 5, 4, 5, 1, 3, 4, 2, 1,
2, 4, 5, 3),byrow = FALSE, ncol = 5)
out = prepare_data(input_rkgs)
input_rkgs = out$input_rkgs
wt = out$wt
## Five input rankings with five objects
## testing the higher the better
input_rkgs <- matrix(c(3, 2, 5, 4, 1, 2, 3, 1, 5, 4, 2, 3, 1, 5, 4, 5, 1, 3, 4, 2, 1,
2, 4, 5, 3),byrow = FALSE, ncol = 5)
input_rkgs = input_rkgs*2+input_rkgs #artificially create a score matrix
# Testing the higher the better rank
out = prepare_data(input_rkgs, HighertheBetter = 1)
input_rkgs = out$input_rkgs
wt = out$wt
Run the code above in your browser using DataLab