Skip to main content

Implementation of majority judgement voting procedure

Project description

===========
Majority Judgement
===========

This is an implementation of the Majority Judgement voting procedure, as
proposed by Michel Balinski and Rida Laraki in [A theory of measuring, electing
, and ranking](http://www.pnas.org/content/104/21/8720.full).

It takes tallies of grades provided by voters and provides a python type to
wrap them which is ordered according to the majority judgement order.

For example:

x = MajorityJudgement([5, 5])
y = MajorityJudgement([3, 7])
assert x < y

The first is the grade for a candidate who has received 5 votes of 0 and 5 votes
of 1. The second is a candidate with 3 votes of 0 and 7 of 1. As a result the
majority judgement procedure ranks the first candidate as being worse than the
second candidate.

In the event that you want more information about the details of the voting,
the MajorityJudgement objects behave like the corresponding lists of grades assigned
to them.

So for example

assert list(MajorityJudgement([2,2])) == [0,1,0,1]

The MajorityJudgement object can generally be used exactly like its corresponding
list of grades.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

majorityjudgement-0.0.1.tar.gz (6.0 kB view details)

Uploaded Source

File details

Details for the file majorityjudgement-0.0.1.tar.gz.

File metadata

File hashes

Hashes for majorityjudgement-0.0.1.tar.gz
Algorithm Hash digest
SHA256 30a925e86c2859d10d03c059a0f16221dcd58eb40a0ca3b5ea232fe30fbcee5d
MD5 aa7fbffe140604edf4287c0d1a8b541a
BLAKE2b-256 52f74227451a88bdda23fc92e88490a3f2014f298b85c97e47b91bfda24b6f68

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page