Namespace: typesVote

typesVote

Type Definitions

pairwiseVote

Properties:
Name Type Attributes Description
netWinsPairwise Array.<Array.<number>> a win, tie, or loss (1,0,-1) for the first of a pair of candidates, indexed by pair.
cansByRank Array.<number> <optional>
an array of candidates lists, indexed by rank. Candidates can share a rank.
ranking Array.<number> <optional>
an array of ranks, indexed by candidate.
bordaScores Array.<number> <optional>
The borda scores for each candidate for one vote.
bordaFractions Array.<number> <optional>
Fractional borda scores, between 0 and 1.
Source:

pluralityVote

Properties:
Name Type Attributes Description
pluralityVote number the chosen candidate. A candidate is represented as an integer from 0 to a max. The max is the number of candidates minus 1.
pluralityAllocation Array.<number> <optional>
an array of 0's except for a 1 for the chosen candidate.
Source:

rankingVote

Properties:
Name Type Attributes Description
cansByRank Array.<number> an array of candidates lists, indexed by rank. Candidates can share a rank.
netWinsPairwise Array.<Array.<number>> <optional>
a win, tie, or loss (1,0,-1) for the first of a pair of candidates, indexed by pair.
ranking Array.<number> <optional>
an array of ranks, indexed by candidate.
bordaScores Array.<number> <optional>
The borda scores for each candidate for one vote.
bordaFractions Array.<number> <optional>
Fractional borda scores, between 0 and 1.
Source:

scoreVote

Properties:
Name Type Description
scoreVote Array.<number> an array of scores, indexed by candidate A score is a number between 0 and 1. In the future, maybe integers between 0 and a maximum score.
Source: