NAME

Vote::Count::Borda

VERSION 1.00

Synopsis

  my $RCV = Vote::Count->new(
    BallotSet  => read_ballots('t/data/data1.txt'),
    bordadepth => 5
  );
  my $bordacount = $RCV->Borda();

Borda Count

Scores Choices based on their position on the Ballot. The first choice candidate gets a score equal to the number of choices, each lower choice recieves 1 less.

Variations mostly relate to altering the Borda Weight for scoring. The original method scored unranked choices at 1, optionally they may be scored as 0 (which is the current module behaviour).

Borda Wieght and Depth

Numerous alternate weightings have been used.

One alternative is to score for the number of choices after the current one -- in a five choice race first is worth 4 and last is worth 0.

One major criticism of the count is that when there are many choices the difference between a first and second choice becomes negligable. Many of the alternate weights address this by either limiting the maximum depth, fixing the depth or using a different scaling such as 1/x where x is the position of the choice (1 is worth 1, 3 is 1/3).

Range Voting Methods such as STAR typically use a fixed depth count where voters may rank choices equally.

When Creating a VoteCount object the Borda weight may be set by passing a coderef. The coderef takes two arguments. The first argument is the position of the choice in question. The second argument is the depth of the ballot. The optional bordadepth attribute will set an arbitrary depth. Some popular options such inversion (where choice $c becomes $c/1 then inverted to 1/$c) don't need to know the depth. In such cases the coderef should just ignore the second argument.

  my $testweight = sub {
    my $x = int shift @_;
    return $x ? 1/$x : 0 ;
  };

  my $VC2 = Vote::Count->new(
    BallotSet   => read_ballots('t/data/data2.txt'),
    bordaweight => $testweight,
  );

Method Borda

Returns a RankCount Object with the scores per the weighting rule, for Ranked Choice Ballots.

Method Score

Returns a RankCount Object with the choices scored using the scores set by the voters, for Range Ballots.

To Do

Since there are so many variations of Borda, it would be nice to offer a large array of presets. Currently options are only handled by passing a coderef at object creation. Borda for RCV is not a priority for the developer.

Private Method _bordashrinkballot( $BallotSet, $active )

Takes a BallotSet and active list and returns a BallotSet reduced to only the active choices. When choices are removed later choices are promoted.

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.