View source: R/voting_methods.R
| av | R Documentation |
Approval Voting (AV) ranks candidates based on the number of voters approving them.
This function uses an internal C++ implementation for efficient computation. For equal weights, a faster R implementation is used.
av(
voters,
candidates,
weights = NULL,
committee_size = NULL,
borda_score = TRUE,
check = FALSE
)
voters |
( |
candidates |
( |
weights |
( |
committee_size |
( |
borda_score |
( |
check |
( |
A data.frame with columns:
"candidate": Candidate names.
"score": Approval scores.
"norm_score": Normalized scores, scaled to the range [0,1].
"borda_score": Borda scores for method-agnostic comparison, ranging in
[0,1], where the top candidate receives a score of 1 and the lowest-ranked
candidate receives a score of 0, based on the total number of candidates.
Candidates are ordered by decreasing "score".
Other voting methods:
sav(),
seq_pav(),
seq_phragmen()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.