Subelection Distance

Subelection Distance#

maximum_common_voter_subelection(election_1, election_2, metric_name='0') int[source]#

This function solves the maximum common voter subelection problem between two elections.

Parameters:
  • election_1 (Election) – The first election.

  • election_2 (Election) – The second election.

  • metric_name (str)

Returns:

The maximum number of common voters between the two elections.

Return type:

int