{"id":21814334,"url":"https://github.com/snawoot/copeland","last_synced_at":"2025-03-21T09:25:53.020Z","repository":{"id":221223682,"uuid":"753777221","full_name":"Snawoot/copeland","owner":"Snawoot","description":"Copeland's preferential voting method implementation.","archived":false,"fork":false,"pushed_at":"2024-02-15T18:23:49.000Z","size":29,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-26T06:11:16.013Z","etag":null,"topics":["copeland","preferential-voting","voting","voting-application","voting-system"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Snawoot.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2024-02-06T19:17:20.000Z","updated_at":"2024-02-11T17:44:46.000Z","dependencies_parsed_at":"2024-02-15T19:34:29.926Z","dependency_job_id":null,"html_url":"https://github.com/Snawoot/copeland","commit_stats":null,"previous_names":["snawoot/copeland"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snawoot%2Fcopeland","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snawoot%2Fcopeland/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snawoot%2Fcopeland/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Snawoot%2Fcopeland/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Snawoot","download_url":"https://codeload.github.com/Snawoot/copeland/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244769571,"owners_count":20507462,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["copeland","preferential-voting","voting","voting-application","voting-system"],"created_at":"2024-11-27T14:37:48.684Z","updated_at":"2025-03-21T09:25:52.996Z","avatar_url":"https://github.com/Snawoot.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# copeland\n\nCopeland's preferential voting method implementation. Outputs Copeland's score and ranking for each candidate.\n\n## Usage\n\n### Create ballot files\n\nJust create plain text files with list of preferences for each voter. One candidate name per line.\n\nExample:\n\na1.txt\n\n```\nBob\nCharlie\nAlice\nDonald\n```\n\na2.txt\n\n```\nDonald\nAlice\nCharlie\nBob\n```\n\na3.txt\n\n```\nAlice\nCharlie\nBob\nDonald\n```\n\n### Run the program\n\n```\ncopeland a1.txt a2.txt a3.txt\n```\n\nExample output:\n\n```\nRegistered names:\n\tALICE\n\tBOB\n\tCHARLIE\n\tDONALD\n\nScores:\n\tRank 1:\n\t\t3\tALICE\n\tRank 2:\n\t\t2\tCHARLIE\n\tRank 3:\n\t\t1\tBOB\n\tRank 4:\n\t\t0\tDONALD\n```\n\nNote: candidate which scored against every other candidate (having score *N-1* with default scoring settings, where *N* is number of candidates), also happens to be a Condorcet winner.\n\n## Synopsis\n\n```\n$ copeland -h\nUsage:\n\ncopeland [OPTION]... [BALLOT FILE OR DIRECTORY]...\n\n  Process files with preference lists and output Copeland's ranking.\n\nOptions:\n  -names string\n    \tfilename of list of names in the voting. If not specified names inferred from first ballot\n  -normalize-case\n    \tnormalize case (default true)\n  -score-loss float\n    \tscore for tie against opponent\n  -score-tie float\n    \tscore for tie against opponent (default 0.5)\n  -score-win float\n    \tscore for win against opponent (default 1)\n  -skip-errors\n    \tskip ballot errors, but still report them\n  -version\n    \tshow program version and exit\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnawoot%2Fcopeland","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsnawoot%2Fcopeland","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnawoot%2Fcopeland/lists"}