matgb: Artwork of 19th century upper class anarchist, text: MatGB (Default)
Mat Bowles ([personal profile] matgb) wrote in [site community profile] dw_suggestions2010-08-13 03:48 am

Have a run-off option for polls

Title:
Have a run-off option for polls

Area:
polls

Summary:
It should be possible to have polls where users ranks options in order of preference (instant runoff or preferential voting).

Description:
Currently we allow for simple plurality voting (radio buttons) and approval voting (checkboxes), but not for preferential voting. As a polling theory geek (involved in the UK campaign for reform) this makes me sad.

We should be able to have polls where a list of options is given, and voters can rank them in order of preference. When the poll is closed, a counting algorithm can be run to reveal which option wins after losing preferences are reassigned.

The code, I think, partially exists for this on LJ as they used it for the advisorty board elections. I don't think it was a good implementation, but it was workable and could probably be improved.

Drawbacks are mostly coding and processing time, as calculating a result will require backened work, especially true if the current result is showing. The LJ implementation is poor and would need improving.

Advantages are that polling geeks like me are very happy, and users can use polls in a more expressive manner. Prefential voting is a good way to organise outings and similar, so good for a journalling site; eg ten people plan a meal together, do they want pizza, burger or that new veggie place, etc...

Poll #4091 Have a run-off option for polls
Open to: Registered Users, detailed results viewable to: All, participants: 46


This suggestion:

View Answers

Should be implemented as-is.
33 (71.7%)

Should be implemented with changes. (please comment)
6 (13.0%)

Shouldn't be implemented.
0 (0.0%)

(I have no opinion)
6 (13.0%)

(Other: please comment)
1 (2.2%)

thorfinn: <user name="seedy_girl"> and <user name="thorfinn"> (Default)

[personal profile] thorfinn 2010-08-13 07:05 am (UTC)(link)
We have preferential voting down here in .au too, and it is good. :-)
ratcreature: RatCreature's toon avatar (Default)

[personal profile] ratcreature 2010-08-13 08:33 am (UTC)(link)
I would only be in favor if this really also could show things before the poll is closed or if you never close it, because that is what all current kinds of polls do. And the scales poll we already have also calculates things. I think it would be strange if one kind of poll behaved differently.
zvi: self-portrait: short, fat, black dyke in bunny slippers (Default)

[personal profile] zvi 2010-08-13 01:52 pm (UTC)(link)
+1
aedifica: Me with my hair as it is in 2020: long, with blue tips (Default)

[personal profile] aedifica 2010-08-13 10:08 pm (UTC)(link)
+1
kerravonsen: (Default)

[personal profile] kerravonsen 2010-08-14 03:19 am (UTC)(link)
+1
pauamma: Cartooney crab wearing hot pink and acid green facemask holding drink with straw (Default)

[personal profile] pauamma 2010-08-13 02:10 pm (UTC)(link)
I'd rather have a "feed raw poll data to a user-configurable S2 thingy" option. That way, you're not stuck with one voting system (or 2, counting the current majority-vote).
pauamma: Cartooney crab wearing hot pink and acid green facemask holding drink with straw (Default)

[personal profile] pauamma 2010-08-13 04:21 pm (UTC)(link)
Depends on the design, but not necessarily. (The "feed poll data to S2 code" part would require a perl-level code change, and that part could be designed with a way to specify a voting system in the form of a style, a view, or something.)
kareila: "PERL!" (perl)

[personal profile] kareila 2010-08-13 03:57 pm (UTC)(link)
The code, I think, partially exists for this on LJ as they used it for the advisory board elections. I don't think it was a good implementation, but it was workable and could probably be improved.

I'm pretty sure we ripped that code out of DW already, so we'd be starting from scratch.
kerravonsen: (Default)

[personal profile] kerravonsen 2010-08-14 03:18 am (UTC)(link)
Oh, I have been wanting this for years!
daweaver:   (pluralism)

[personal profile] daweaver 2010-08-18 05:34 pm (UTC)(link)
We should be able to have polls where a list of options is given, and voters can rank them in order of preference.

So the voter would see something along the lines of...

What is your favourite vowel?
[] A
[] E
[] I
[] O
[] U
[] W
[] Y


with [] replaced by a drop-down containing numbers 1 to 7 and a blank.

Back-end checking at vote time would ensure that the voter had specified a strict sequence, with no number repeated. Is it necessary to check that voting runs 1, 2, 3? Not strictly according to the mathematics, but it would make the coding so much easier.

The count is initially of first-preference votes, then re-assigning the least popular first-prefs to their second and so on until one option achieves a majority of initially valid votes. (Or a majority of effective votes.)

The code, I think, partially exists for this on LJ as they used it for the advisory board elections. I don't think it was a good implementation, but it was workable and could probably be improved.

The biggest problem in Livejournal's code was that they restricted people to a finite number of picks from a list of candidates, rather than numbering their votes. The handling of tied eliminations was also sloppy, eliminating all candidates involved in a tie; preference tends to be a countback method and/or conditional eliminations.

If this aspect is going to be done properly, it may be possible to provide a single transferrable vote to return multiple winners. Where would this have a practical application? "Two of these seven vowels are going forward to our Favourite Letter poll." One-winner transferrable vote is just a degenerate case of multi-winner.

Drawbacks are mostly coding and processing time, as calculating a result will require backened work, especially true if the current result is showing.

Coding is a one-time hit, processing is an ongoing matter. I would not be averse to cacheing the result, and only recalculating it after increasing intervals - for the sake of argument after 15 minutes, 30 minutes, 1 hour, 2 hours, 4, 8, 12 hours, and so on. Closing the poll forces a count, natch.

The LJ implementation is poor and would need improving.

The wheel has already been invented. Implementers may wish to consider the algorithm embedded in the source code for http://www.openstv.org/download as a starting point.