votes
    Preparing search index...

    Class Election<C>

    Chains methods: the first ranks the candidates, each next one re-ranks the tiers still tied. A round method breaks its round ties with the methods after it.

    new Election({
    candidates,
    ballots,
    methods: [InstantRunoff, Schulze, RandomCandidates.with({ rng })],
    })

    Type Parameters

    • C extends string

    Implements

    Index
    • Ranking built by repeated wins: run the full election, record the winning tier, then re-run the whole election restricted to the remaining candidates for the next place, and so on. See Method#iteratedRanking.

      Returns C[][]

    • Returns C[][]

    • The same ranker on a subset of its candidates.

      Parameters

      • candidates: readonly C[]

      Returns Election<C>