NAME
Vote::Count::RankCount
VERSION 0.11
Rank
Takes a single argument of a hashref containing Choices as Keys and Votes as Values. Returns an Object. This method is also aliased as new.
Methods
RawCount
Returns the original HashRef used for Object Creation.
HashWithOrder
Returns a HashRef with the Choices as Keys and the position of the choice, the value for the Leader would be 1 and the Third Place Choice would be 3.
HashByRank
Returns a HashRef where the keys are numbers and the values an ArrayRef of the Choices in that position. The ArrayRefs are sorted alphanumerically.
ArrayTop, ArrayBottom
Returns an ArrayRef of the Choices in the Top or Bottom Positions.
CountVotes
Returns the number of votes in the RawCount. This is not the same as the votes in the BallotSet from which that was derived. For TopCount it is the number of non-exhausted ballots in the round that generated RawCount, for Approval and Boorda it is probably not useful.
Leader
Returns a HashRef with the keys tie, tied, winner where winner is the winner, tie is true or false and tied is an array ref of the choices in the tie.
RankTable
Generates a MarkDown formatted table.
BUG TRACKER
https://github.com/brainbuz/Vote-Count/issues
AUTHOR
John Karr (BRAINBUZ) brainbuz@cpan.org
CONTRIBUTORS
Copyright 2019 by John Karr (BRAINBUZ) brainbuz@cpan.org.
LICENSE
This module is released under the GNU Public License Version 3. See license file for details. For more information on this license visit http://fsf.org.