X-Git-Url: https://projects.mako.cc/source/rubyvote/blobdiff_plain/1217d8139176963d7c2693e76c0da7910631d9fa..c9649b477b0e94c4f7f36e6d42225e0d6a113f57:/lib/rubyvote/positional.rb diff --git a/lib/rubyvote/positional.rb b/lib/rubyvote/positional.rb index 056194b..d72f8a7 100644 --- a/lib/rubyvote/positional.rb +++ b/lib/rubyvote/positional.rb @@ -29,6 +29,19 @@ ## These classes inherit from and/or are modeled after the classes in ## election.rb and condorcet.rb +# Borda is a positional voting system and, as a result, takes a list of +# ranked candidates and assigns points to each candidates based on their +# order. In Borda, there are *n* candidate and the first candidates is +# assigned *n* - 1 points and each subsequent candidate is assigned one +# less point. The candidate is assigned no points. +# +# Currently, all candidates should be ranked in each ballot. +# +# Example:: +# +# require 'positional' +# vote_array = [ ["A", "B"], ["B", "A"], ["B", "A"] ] +# resultobject = BordaVote.new(vote_array).result class BordaVote < ElectionVote def initialize(votes=nil)