MyCondorcetAlgorithm

class MyCondorcetAlgorithm<S : ScoreMetric>(var pollAlgorithmParameters: List<PollAlgorithmParameter> = listOf()) : PollAlgorithm<S, ListOfPreferencesVote<S>>

Represents an algorithm implementing Condorcet logic.

Constructors

Link copied to clipboard
constructor(pollAlgorithmParameters: List<PollAlgorithmParameter> = listOf())

Properties

Link copied to clipboard
lateinit var candidates: List<Competitor<S>>

List of candidates, useful to check pre-conditions before executing the computation.

Link copied to clipboard

List of parameters.

Functions

Link copied to clipboard

Compute the final ranking, given the votes.

Link copied to clipboard
open operator fun PollAlgorithmParameter.unaryPlus()

Shortcut useful to add an element in pollAlgorithmParameters.