Description Usage Arguments Value Examples
View source: R/HighestMedianRules.R
Returns a matrix with the scores of candidates sorted in decreasing order, for a given voting rule.
1 2 3 4 5 6 7 8 |
grades |
A voting profile, i.e. a matrix with the shares of grades of each candidate on each row, from the lowest grade to the highest. |
rule |
The voting rule to be used. Default to 'mj'. Possible values: 'mj' (majority judgment), 'd' (difference), 's' (relative share), 'n' (normalized difference), 'mean' (range voting). For more details, see "Tie-Breaking the Highest Median", Fabre, Social Choice & Welfare (forthcoming). |
k |
The quantile used to compute the gauge. Default to 0.5 (the median). For more details, see paragraph Extensions in 3.2.1 of "Tie-Breaking the Highest Median", Fabre, Social Choice & Welfare (forthcoming). |
scale |
A numeric vector containing the values of the scale of grades. Default to c((floor(-length(grades)/2)+1):(length(grades)+floor(-length(grades)/2))). |
names |
String vector, each string to be printed in case print = TRUE. Defaults to c(). |
print |
Prints the argument 'names'. Default to FALSE |
A character matrix with as many rows as elements of grades
, and with the name, gauge and score (according to rule
) on each row.
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.