bioconsert¶
- class corankco.algorithms.bioconsert.bioconsert.BioConsert(starting_algorithms: Collection[MedianRanking] | None = None)¶
BioConsert is a heuristics for Kemeny-Young rank aggregation published in Cohen-Boulakia, Sarah & Denise, Alain & Hamel, Sylvie. (2011). Using Medians to Generate Consensus Rankings for Biological Data. 6809. 73-90. 10.1007/978-3-642-22351-8_5. Complexity: O(nb_elements² * nb_rankings) on empirical results (not proved) Had best quality results on benchmark (complete rankings) in Brancotte et al. (2015). Rank aggregation with ties: Experiments and Analysis. For time computation reasons, a part of this algorithm is written in C
- compute_consensus_rankings(dataset: Dataset, scoring_scheme: ScoringScheme, return_at_most_one_ranking=False, bench_mode=False) Consensus ¶
Calculate and return the consensus rankings based on the given dataset and scoring scheme.
- Parameters:
dataset (Dataset) – The dataset of rankings to be aggregated.
scoring_scheme (ScoringScheme) – The scoring scheme to be used for calculating consensus.
return_at_most_one_ranking (bool) – If True, the algorithm should return at most one ranking.
bench_mode (bool) – If True, the algorithm may return additional information for benchmarking purposes.
- Returns:
Consensus rankings. If the algorithm is unable to provide multiple consensuses or
return_at_most_one_ranking is True, a single consensus ranking is returned. :rtype: Consensus :raise ScoringSchemeNotHandledException: When the algorithm cannot compute the consensus because the implementation does not support the given scoring scheme.
- get_full_name() str ¶
- Returns:
the name of the Algorithm i.e. “BioConsert with ” + information on the departure algorithms if not None
- is_scoring_scheme_relevant_when_incomplete_rankings(scoring_scheme: ScoringScheme) bool ¶
Check if the scoring scheme is relevant when the rankings are incomplete.
- Parameters:
scoring_scheme (ScoringScheme) – The scoring scheme to be checked.
- Returns:
True iif all the starting algorithms are compatible with the scoring scheme
- Return type:
bool