Allocated Score: Difference between revisions

From electowiki
Content added Content deleted
m (→‎Procedure: Deleted broken image)
 
(7 intermediate revisions by 4 users not shown)
Line 1: Line 1:


[[Allocated Score]] is a [[proportional representation]] voting method using [[Score Voting|5 star ballots]]. Otherwise known as ''Proportional STAR'' Voting, this method is one of three voting methods in the STAR Voting family, which includes[[Single-member district | single-winner]] [[STAR voting]], multi-winner [[STAR voting|Bloc STAR Voting]], and Proportional STAR. In the multi-winner context STAR stands for Score Then Automatic Runoffs.
[[Allocated Score]] is a [[proportional representation]] voting method using [[Score Voting|5-star ballots]]. Otherwise known as '''Proportional STAR Voting''' ('''STAR PR'''),<ref>{{Cite web|url=https://www.starvoting.org/star-pr|title=Proportional STAR Voting|website=STAR Voting|language=en|access-date=2023-05-13}}</ref> this method is one of three voting methods in the STAR Voting family, which includes[[Single-member district | single-winner]] [[STAR voting]], multi-winner [[STAR voting|Bloc STAR Voting]], and Proportional STAR. In the multi-winner context, STAR stands for "Score Then Automatic Runoffs".


Allocation is the default mechanism for achieving [[proportional representation]] in voting methods. Winners are selected in rounds. Each round elects the candidate with the highest total score. After each selection, the Hare quota of ballots which scored the winner the highest is allocated to them, and as such those ballots are removed from subsequent rounds. Ballots on the cusp of the quota may only have their ballots partially allocated to ensure that voters who supported the winner equally are treated equally.
Allocation is the default mechanism for achieving [[proportional representation]] in voting methods. Winners are selected in rounds. Each round elects the candidate with the highest total score. After each selection, the [[Hare quota]] of ballots which scored the winner the highest is allocated to that winner, and as such those ballots are removed from subsequent rounds. Ballots on the cusp of the quota may only have their ballots partially allocated to ensure that voters who supported the winner equally are treated equally.


== Description ==
== Description ==
[[File:Proportional STAR Ballot - STAR-PR.png|alt=A sample STAR-PR ballot showing scores for each candidate ranging from 0 up to 5 stars. At the top of the ballot are voter instructions, and at the bottom a simple description of how votes are counted.|thumb|A sample STAR-PR ballot]]
[[File:Proportional STAR Ballot - STAR-PR.png|alt=A sample STAR-PR ballot showing scores for each candidate ranging from 0 up to 5 stars. At the top of the ballot are voter instructions, and at the bottom a simple description of how votes are counted.|thumb|A sample STAR-PR ballot]]
Winners in Proportional STAR Voting (Allocated Score) are selected in rounds. Each round elects the candidate with the highest total score and then designates a quota worth of voters from that candidate's strongest supporters as represented. Subsequent rounds include all voters who are not yet fully represented.
Winners in Proportional STAR Voting (Allocated Score) are selected in rounds. Each round elects the candidate with the highest total score and then designates a quota's worth of voters from that candidate's strongest supporters as fully represented. Subsequent rounds include all voters who are not yet fully represented.


== Classification ==
== Classification ==
Allocated Score is a [[Cardinal_voting_systems#Sequential_Proportional_Methods | sequential]], [[Multi-Member System|multi-winner]], [[Cardinal voting systems|cardinal]], [[Monroe's method|Monroe type]], [[proportional representation]] voting method.
Allocated Score is a [[Cardinal voting systems#Sequential proportional methods|sequential]], [[Multi-Member System|multi-winner]], [[Cardinal voting systems|cardinal]], [[Monroe's method|Monroe-type]], [[proportional representation]] voting method.


==Procedure==
==Procedure==
Line 15: Line 15:
Each voter scores all candidates on a [0,5] scale
Each voter scores all candidates on a [0,5] scale


# Select the candidate with the highest sum of score as each round's winner.
# Select the candidate with the highest sum of scores as each round's winner.
# Set the ballot weight to zero for the [[quota]] of voters whose ballots contributed the highest scores to that winner.
# Set the ballot weight to zero for the [[quota]] of voters whose ballots contributed the highest scores to that winner.
#* If several voters have contributed the same score to the winner at the threshold of the quota then [[Fractional Surplus Handling]] is applied to those voters
#* If several voters have contributed the same score to the winner at the threshold of the quota then [[Fractional Surplus Handling]] is applied to those voters
Line 24: Line 24:
When multiple voters contributed the same score to the winner it may be the case that allocating them all to the winner would cause the quota to be exceeded but not allocating them all would cause the quota not to be met. For these voters on the cusp, an equal fraction of their ballot weight is allocated.
When multiple voters contributed the same score to the winner it may be the case that allocating them all to the winner would cause the quota to be exceeded but not allocating them all would cause the quota not to be met. For these voters on the cusp, an equal fraction of their ballot weight is allocated.


Fractional Surplus Handling ensures that voters who supported a candidate equally will be treated equally, while ensuring that the total weight of the ballots allocated for each winner will not exceed the Hare quota. It also preserves the [[Independence of irrelevant alternatives|Independence of Irrelevant Alternatives]] and [[Monotonicity]] criteria {{Citation_needed}}.
Fractional Surplus Handling ensures that voters who supported a candidate equally will be treated equally, while ensuring that the total weight of the ballots allocated for each winner will not exceed the Hare quota. It also preserves the [[Independence of irrelevant alternatives|Independence of Irrelevant Alternatives]] and [[Monotonicity]] criteria.{{Citation_needed}}


Note that with Fractional Surplus Handling voters can have a fractional ballot weight and they can subsequently only contribute that fraction to the remaining candidates, both during subsequent score tabulation and allocation.
Note that with Fractional Surplus Handling voters can have a fractional ballot weight and they can subsequently only contribute that fraction to the remaining candidates, both during subsequent score tabulation and allocation.


Warning: The sort must be done on the weighted score not the original score or the mismatch between the selection and elimination will cause a free riding issue. <ref>https://forum.electionscience.org/t/system-chosen-by-the-wolf-committee/875/30</ref>
Warning: The sort must be done on the weighted score (not the original score from the ballots) or the mismatch between the selection and elimination will cause a free riding issue.<ref>https://forum.electionscience.org/t/system-chosen-by-the-wolf-committee/875/30</ref>
==Python implementation==


Given a Pandas dataframe '''S''' with columns representing candidates and rows representing voters the entries would encode the score of all the ballots. For a max score of '''K''' and a desired number of winners '''W'''.


<source lang="python">


def Allocated_Score(ballots: pd.DataFrame, seats: int, max_score: int):
==Python Implementation==
"""Credit to https://electowiki.org/wiki/Allocated_Score
Allocated Score is another name for STAR-PR


Parameters:
Given a Pandas dataframe '''S''' with columns representing candidates and rows representing voters the entries would encode the score of all the ballots. For a max score of '''K''' and a desired number of winners '''W'''.


"""
<source lang="python">
# Normalize score matrix
import pandas as pd
ballots = pd.DataFrame(ballots.values / max_score, columns=ballots.columns)
import numpy as np


# Find number of voters and quota size
def Allocated_Score(K, W, S):
voters = ballots.shape[0]
quota = voters / seats
ballot_weight = pd.Series(np.ones(voters), name="weights")


# Populate winners in a loop
#Normalize score matrix
ballots = pd.DataFrame(S.values/K, columns=S.columns)
#Find number of voters and quota size
V = ballots.shape[0]
quota = V/W
ballot_weight = pd.Series(np.ones(V),name='weights')
#Populate winners in a loop
winner_list = []
winner_list = []
while len(winner_list) < W:
while len(winner_list) < seats:


weighted_scores = ballots.multiply(ballot_weight, axis="index")
weighted_scores = ballots.multiply(ballot_weight, axis="index")


#Select winner
# Select winner
w = weighted_scores.sum().idxmax()
winner = weighted_scores.sum().idxmax()
#Add winner to list
winner_list.append(w)


#remove winner from ballot
# Add winner to list
ballots.drop(w, axis=1, inplace=True)
winner_list.append(winner)
#Create lists for manipulation
cand_df = pd.concat([ballot_weight,weighted_scores[w]], axis=1).copy()
cand_df_sort = cand_df.sort_values(by=[w], ascending=False).copy()
#find the score where a quota is filled
split_point = cand_df_sort[cand_df_sort['weights'].cumsum() < quota][w].min()
#Amount of ballot for voters who voted more than the split point
spent_above = cand_df[cand_df[w] > split_point]['weights'].sum()
#Exhaust all ballots above split point
if spent_above>0:
cand_df.loc[cand_df[w] > split_point, 'weights'] = 0.0
#Amount of ballot for voters who gave a score on the split point
weight_on_split = cand_df[cand_df[w] == split_point]['weights'].sum()


#Fraction of ballot on split needed to be spent
# remove winner from ballot
ballots.drop(winner, axis=1, inplace=True)
if weight_on_split>0:
spent_value = (quota - spent_above)/weight_on_split
#Take the spent value from the voters on the threshold evenly
cand_df.loc[cand_df[w] == split_point, 'weights'] = cand_df.loc[cand_df[w] == split_point, 'weights'] * (1 - spent_value)
ballot_weight = cand_df['weights'].clip(0.0,1.0)


# Create lists for manipulation
return winner_list
cand_df = pd.concat([ballot_weight, weighted_scores[winner]], axis=1).copy()
cand_df_sort = cand_df.sort_values(by=[winner], ascending=False).copy()


# find the score where a quota is filled
split_point = cand_df_sort[cand_df_sort["weights"].cumsum() < quota][
winner
].min()

# Amount of ballot for voters who voted more than the split point
spent_above = cand_df[cand_df[winner] > split_point]["weights"].sum()

# Allocate all ballots above split point
if spent_above > 0:
cand_df.loc[cand_df[winner] > split_point, "weights"] = 0.0

# Amount of ballot for voters who gave a score on the split point
weight_on_split = cand_df[cand_df[winner] == split_point]["weights"].sum()

# Fraction of ballot on split needed to be spent
if weight_on_split > 0:
spent_value = (quota - spent_above) / weight_on_split

# Take the spent value from the voters on the threshold evenly
cand_df.loc[cand_df[winner] == split_point, "weights"] = cand_df.loc[
cand_df[winner] == split_point, "weights"
] * (1 - spent_value)

ballot_weight = cand_df["weights"].clip(0.0, 1.0)

return winner_list
</source>
</source>


Line 98: Line 101:


===Quota===
===Quota===
A common variant is to use Droop quotas instead of Hare quotas to mitigate [[Free riding]].
A common variant is to use Droop quotas instead of Hare quotas to mitigate [[free riding]]. However, this modification also results in a bias towards larger parties.


===Sequential Monroe===
===Sequential Monroe===
Line 105: Line 108:


== History ==
== History ==
Allocated Score is the natural extension of applying vote allocation to score ballots. While there are a number of variations on the theme that can be done, the Allocated Score method is the simplest which delivers great results. Beginning in 2018, The Equal Vote 0-5 Star Proportional Representation Research Committee spent two years comparing and studying the options at each stage in the tabulation process and ultimately, thanks to the work of Parker Friedland, [[Keith Edmonds]], Jameson Quinn, Sara Wolk, and a number of others, found Allocated Score to be the committee's consensus method, balancing competing considerations while meeting core criteria.
Allocated Score is the natural extension of applying vote allocation to score ballots. While there are a number of variations on the theme that can be done, the Allocated Score method is the simplest which delivers great results. Beginning in 2018, The Equal Vote 0-5 Star Proportional Representation Research Committee spent two years comparing and studying the options at each stage in the tabulation process and ultimately, thanks to the work of Parker Friedland, [[Keith Edmonds]], [[Jameson Quinn]], [[Sara Wolk]], and a number of others, found Allocated Score to be the committee's consensus method, balancing competing considerations while meeting core criteria.<ref>{{Cite web|url=https://web.archive.org/web/20210227125039/https://forum.electionscience.org/t/system-chosen-by-the-wolf-committee/875|title=System chosen by the Wolf committee - Campaigns - Voting Methods Forum|date=2021-02-27|website=web.archive.org|access-date=2023-05-14}}</ref>

== References ==
[[Category:Cardinal voting methods]]
[[Category:Proportional voting methods]]
[[Category:Multi-winner voting methods]]
[[Category:Cardinal PR methods]]
[[Category:Cardinal PR methods]]
[[Category:Monotonic electoral systems]]
[[Category:Largest remainder-reducing voting methods]]
[[Category:Largest remainder-reducing voting methods]]

Latest revision as of 18:43, 7 March 2024

Allocated Score is a proportional representation voting method using 5-star ballots. Otherwise known as Proportional STAR Voting (STAR PR),[1] this method is one of three voting methods in the STAR Voting family, which includes single-winner STAR voting, multi-winner Bloc STAR Voting, and Proportional STAR. In the multi-winner context, STAR stands for "Score Then Automatic Runoffs".

Allocation is the default mechanism for achieving proportional representation in voting methods. Winners are selected in rounds. Each round elects the candidate with the highest total score. After each selection, the Hare quota of ballots which scored the winner the highest is allocated to that winner, and as such those ballots are removed from subsequent rounds. Ballots on the cusp of the quota may only have their ballots partially allocated to ensure that voters who supported the winner equally are treated equally.

Description

A sample STAR-PR ballot showing scores for each candidate ranging from 0 up to 5 stars. At the top of the ballot are voter instructions, and at the bottom a simple description of how votes are counted.
A sample STAR-PR ballot

Winners in Proportional STAR Voting (Allocated Score) are selected in rounds. Each round elects the candidate with the highest total score and then designates a quota's worth of voters from that candidate's strongest supporters as fully represented. Subsequent rounds include all voters who are not yet fully represented.

Classification

Allocated Score is a sequential, multi-winner, cardinal, Monroe-type, proportional representation voting method.

Procedure

Each voter scores all candidates on a [0,5] scale

  1. Select the candidate with the highest sum of scores as each round's winner.
  2. Set the ballot weight to zero for the quota of voters whose ballots contributed the highest scores to that winner.
    • If several voters have contributed the same score to the winner at the threshold of the quota then Fractional Surplus Handling is applied to those voters
  3. Repeat this process until all the seats are filled.

Fractional Surplus Handling: When determining which ballots belong to a winner's quota, voter’s ballots are sorted by the score they contributed to the winner's total score.

When multiple voters contributed the same score to the winner it may be the case that allocating them all to the winner would cause the quota to be exceeded but not allocating them all would cause the quota not to be met. For these voters on the cusp, an equal fraction of their ballot weight is allocated.

Fractional Surplus Handling ensures that voters who supported a candidate equally will be treated equally, while ensuring that the total weight of the ballots allocated for each winner will not exceed the Hare quota. It also preserves the Independence of Irrelevant Alternatives and Monotonicity criteria.[citation needed]

Note that with Fractional Surplus Handling voters can have a fractional ballot weight and they can subsequently only contribute that fraction to the remaining candidates, both during subsequent score tabulation and allocation.

Warning: The sort must be done on the weighted score (not the original score from the ballots) or the mismatch between the selection and elimination will cause a free riding issue.[2]

Python implementation

Given a Pandas dataframe S with columns representing candidates and rows representing voters the entries would encode the score of all the ballots. For a max score of K and a desired number of winners W.

def Allocated_Score(ballots: pd.DataFrame, seats: int, max_score: int):
    """Credit to https://electowiki.org/wiki/Allocated_Score
    Allocated Score is another name for STAR-PR

    Parameters:

    """
    # Normalize score matrix
    ballots = pd.DataFrame(ballots.values / max_score, columns=ballots.columns)

    # Find number of voters and quota size
    voters = ballots.shape[0]
    quota = voters / seats
    ballot_weight = pd.Series(np.ones(voters), name="weights")

    # Populate winners in a loop
    winner_list = []
    while len(winner_list) < seats:

        weighted_scores = ballots.multiply(ballot_weight, axis="index")

        # Select winner
        winner = weighted_scores.sum().idxmax()

        # Add winner to list
        winner_list.append(winner)

        # remove winner from ballot
        ballots.drop(winner, axis=1, inplace=True)

        # Create lists for manipulation
        cand_df = pd.concat([ballot_weight, weighted_scores[winner]], axis=1).copy()
        cand_df_sort = cand_df.sort_values(by=[winner], ascending=False).copy()

        # find the score where a quota is filled
        split_point = cand_df_sort[cand_df_sort["weights"].cumsum() < quota][
            winner
        ].min()

        # Amount of ballot for voters who voted more than the split point
        spent_above = cand_df[cand_df[winner] > split_point]["weights"].sum()

        # Allocate all ballots above split point
        if spent_above > 0:
            cand_df.loc[cand_df[winner] > split_point, "weights"] = 0.0

        # Amount of ballot for voters who gave a score on the split point
        weight_on_split = cand_df[cand_df[winner] == split_point]["weights"].sum()

        # Fraction of ballot on split needed to be spent
        if weight_on_split > 0:
            spent_value = (quota - spent_above) / weight_on_split

            # Take the spent value from the voters on the threshold evenly
            cand_df.loc[cand_df[winner] == split_point, "weights"] = cand_df.loc[
                cand_df[winner] == split_point, "weights"
            ] * (1 - spent_value)

        ballot_weight = cand_df["weights"].clip(0.0, 1.0)

    return winner_list

Variants

Quota

A common variant is to use Droop quotas instead of Hare quotas to mitigate free riding. However, this modification also results in a bias towards larger parties.

Sequential Monroe

Sequential Monroe can be thought of as a variant of Allocated Score with a change to the selection method.

History

Allocated Score is the natural extension of applying vote allocation to score ballots. While there are a number of variations on the theme that can be done, the Allocated Score method is the simplest which delivers great results. Beginning in 2018, The Equal Vote 0-5 Star Proportional Representation Research Committee spent two years comparing and studying the options at each stage in the tabulation process and ultimately, thanks to the work of Parker Friedland, Keith Edmonds, Jameson Quinn, Sara Wolk, and a number of others, found Allocated Score to be the committee's consensus method, balancing competing considerations while meeting core criteria.[3]

References

  1. "Proportional STAR Voting". STAR Voting. Retrieved 2023-05-13.
  2. https://forum.electionscience.org/t/system-chosen-by-the-wolf-committee/875/30
  3. "System chosen by the Wolf committee - Campaigns - Voting Methods Forum". web.archive.org. 2021-02-27. Retrieved 2023-05-14.